KeyWord:沙盒文件递归遍历、Swift里的闭包多个weak修饰、iOS使用AirDrop
操作演示.gif
平时真机开发调试App的时候想查看沙盒具体内容一般做法是连接Xcode下载整个App的沙盒,不方便,于是自己写了一个沙盒查看器。
如何导入使用
Swift下
1.拖入文件夹FHHSandBoxViewer到你的工程;
2.找个入口然后添加如下代码:
let title = FHHSandboxViewController.defaultNavTitle
let path = FHHSandboxViewController.defaultPath
let sandBoxViewerVC = FHHSandboxViewController.init(navTitle: title, path: path)
let nav = UINavigationController.init(rootViewController: sandBoxViewerVC)
nav.navigationBar.isHidden = true
nav.navigationBar.isTranslucent = true
self.present(nav, animated: true, completion: {
sandBoxViewerVC.fhh_enterType = .present
})
OC下
1.拖入文件夹FHHSandBoxViewer到你的工程;
2.如果你的项目之前没有使用Swift,需要配置你Xcode的ProductName-Bridging-Hea