iOS App 版本更新后,Library/cache 文件夹会不会被覆盖(或清空)?
答案:1 悬赏:70 手机版
解决时间 2021-03-05 00:12
- 提问者网友:未信
- 2021-03-04 11:06
iOS App 版本更新后,Library/cache 文件夹会不会被覆盖(或清空)?
最佳答案
- 五星知识达人网友:拜訪者
- 2021-03-04 12:45
不会覆盖。@张剑 document目录会自动同步到icloud,所以按照iOS data storage guidelines, 这里最好只放用户手动产生的数据。当然你可以根据file attributes禁止同步icloud。另外,违反这个规定,会违反Apple的2.23号规则,并被Reject。关于iOS data storage guidelines,请参见:https://developer.apple.com/icloud/documentation/data-storage/我这里摘录几个要点:1. Only documents and other data that is user-generated, or that
cannot otherwise be recreated by your application, should be stored in
the <Application_Home>/Documents directory and will be automatically backed up by iCloud.2. Data that can be downloaded again or regenerated should be stored in the <Application_Home>/Library/Caches
directory. Examples of files you should put in the Caches directory
include database cache files and downloadable content, such as that used
by magazine, newspaper, and map applications.3. Data that is used only temporarily should be stored in the <Application_Home>/tmp
directory. Although these files are not backed up to iCloud, remember
to delete those files when you are done with them so that they do not
continue to consume space on the user’s device.
我要举报
如以上问答信息为低俗、色情、不良、暴力、侵权、涉及违法等信息,可以点下面链接进行举报!
大家都在看
推荐资讯