iOS文件存储路径规定
Storing Your App’s Data Efficiently
https://developer.apple.com/icloud/documentation/data-storage/index.html
总结: 用户产生的: 存储在Documents, 会被备份到iCloud
程序产生的: 如数据库, 下载的缓存图片, 存储在 Library/Caches
临时的文件: 存储再Temp目录, 用完记得删
To ensure that backups are as efficient as possible, store your app’s data according to the following guidelines:
- 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.
- 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.
- 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.
- Use the "do not back up" attribute for specifying files that should remain on device, even in low storage situations. Use this attribute with data that can be recreated but needs to persist even in low storage situations for proper functioning of your app or because customers expect it to be available during offline use. This attribute works on marked files regardless of what directory they are in, including the Documents directory. These files will not be purged and will not be included in the user's iCloud or iTunes backup. Because these files do use on-device storage space, your app is responsible for monitoring and purging these files periodically.
iOS文件存储路径规定的更多相关文章
- unity中的文件存储路径与各平台(Android,iOS)的关系
原文链接:unity中的文件存储路径与各平台(Android,iOS)的关系 主要是这个问题困扰我了一阵子,所以特写写... unity中的的各种存储方法的对应关系(直接上截图吧) 重点说的是Appl ...
- 截取linux文件存储路径方法
1.截取linux文件存储路径方法 package com.tydic.eshop.action.freemarker; public class dddd { public static void ...
- 转:Android文件存储路径getFilesDir()与getExternalFilesDir的区别
作为一个开发者,我们经常需要通过缓存一些文件到SD卡中,常见的方式就是,通过: File sdCard = Environment.getExternalStorageDirectory(); 获取S ...
- 修改Jupyter Notebook默认文件存储路径(已安装Anaconda)
https://blog.csdn.net/weixin_44799144/article/details/91823079 修改Jupyter Notebook默认文件存储路径首先,安装好Anaco ...
- 【HANA系列】SAP HANA的ini文件存储路径
公众号:SAP Technical 本文作者:matinal 原文出处:http://www.cnblogs.com/SAPmatinal/ 原文链接:[HANA系列]SAP HANA的ini文件存储 ...
- IOS文件存储小结
转自:http://tyragain.lofter.com/post/84706_c1503 首选项设置存储 NSUserDefaults 以及通过它控制的SettingBundle NSUserD ...
- up6-自定义文件存储路径
在up6.2中有两种保存模式,一种是md5一种是uuid. md5由PathMd5Builder生成存储路径.md5主要提供给文件使用,可在服务器端保存唯一的文件,有效避免重复文件. uuid由Pat ...
- iOS 5 does not allow to store downloaded data in Documents directory? ios5.0及以后的版本对于下载的文件存储路径有了改变
I have made an application for my client by keeping target iOS as 4. But since the application still ...
- Outlook IMAP 修改PST文件存储路径
IMAP类型的账户修改PST文件位置方法: 对于IMAP类型账户的PST文件,既没有“修改文件夹”的选项,也无法按OFFICE官方操作指南中的操作.因为每次Outlook只要检测到默认路径下的PST文 ...
随机推荐
- Git.Framework 框架随手记--准备工作
前面已经提到过了本框架的由来,时至今日该框架已经和最初版本有了天壤之别.因为仍有部分代码是采用原有的框架,所以本框架也算不上原创,只是在原有的基础上不断的改进,所以希望了解此框架的人不要过多的指责. ...
- css自定义字体
@font-face { font-family: 华文隶书; src: url( ../font/STLITI.eot ); /* IE */ src: url( ../font/STLITI.tt ...
- 第二章:Javascript词法结构
编程语言的词法结构是一套基础性的规则,用来描述你如何编写这门语言.作为语法的基础,它规定了变量名是怎么样的,如何写注释,以及语句之间是如何区分的.本节用很短的篇幅来介绍javascript的词法结构. ...
- F12调试打开时,出现很多多余内容问题解决
关闭vs2013的browserlink功能即可: <appSettings> <add key="vs:EnableBrowserLink" value=&qu ...
- 第一节Unity3D简介
Unity是由Unity Technologies开发的一个让玩家轻松创建诸如三维视频游戏.建筑可视化.实时三维动画等类型互动内容的多平台的综合型游戏开发工具,是一个全面整合的专业游戏引擎.Unity ...
- 图片百分百问题 z-index问题
遇到的问题: 1.图片设置宽高都为100%,为什么高度没有100%呢? 我日了狗了! 答:因为图片默认高度大于包含框, 此时元素的高度100%将不会参照父元素? 继承出现了问 ...
- Cas_个人理解
分为三个部分: 1.Cas服务器(用于验证用户是否正确) 1.用户信息存在服务端,其它客户端应用程序修改用户信息后需要同步到服务端 2.用户信息一般存储在服务端的数据 ...
- Shell good example
(1) Source code #! /bin/bash reference () { pa=\$"$1" echo $pa x=`eval &qu ...
- 【HDU 5007】Post Robot
Description DT is a big fan of digital products. He writes posts about technological products almost ...
- [NOIP2010] 提高组 洛谷P1540 机器翻译
题目背景 小晨的电脑上安装了一个机器翻译软件,他经常用这个软件来翻译英语文章. 题目描述 这个翻译软件的原理很简单,它只是从头到尾,依次将每个英文单词用对应的中文含义来替换.对于每个英文单词,软件会先 ...