ios文件管理

<Application_Home>/AppName.app

This is the bundle directory containing the application
itself. Do not write anything to this directory. To prevent
tampering, the bundle directory is signed at installation
time. Writing to this directory changes the signature and
prevents your application from launching again.
In iOS 2.1 and later, the contents of this directory are not
backed up by iTunes. However, iTunes does perform an
initial sync of any applications purchased from the App
Store.

 

<Application_Home>/Documents/

Use this directory to store user documents and application
data files. The contents of this directory can be made
available to the user through file sharing, which is
described in “Sharing Files with the User’s Desktop
Computer” (page 18).
The contents of this directory are backed up by iTunes.

 

<Application_Home>/Library/

This directory is the top-level directory for files that are
not user data files. You typically put files in one of several
standard subdirectories but you can also create custom
subdirectories for files you want backed up but not
exposed to the user. (For information on how to get
references to the standard subdirectories, see “Getting
Paths to Standard Application Directories” (page 51).)
You should not use this directory for user data files.
The contents of this directory (with the exception of the
Caches subdirectory) are backed up by iTunes.

 

<Application_Home>/Library/Preferences

This directory contains application-specific preference
files. You should not create preference files directly but
should instead use the NSUserDefaults class or
CFPreferences API to get and set application preferences;
see also “Adding the Settings Bundle” (page 78).
The contents of this directory are backed up by iTunes.

 

<Application_Home>/Library/Caches

Use this directory to write any application-specific support
files that you want to persist between launches of the
application or during application updates. Your
application is generally responsible for adding and
removing these files. It should also be able to re-create
these files as needed because iTunes removes them
during a full restoration of the device.
In iOS 2.2 and later, the contents of this directory are not
backed up by iTunes.

 

<Application_Home>/tmp/

Use this directory to write temporary files that do not
need to persist between launches of your application.
Your application should remove files from this directory
when it determines they are no longer needed. (The
system may also purge lingering files from this directory
when your application is not running.)
In iOS 2.1 and later, the contents of this directory are not
backed up by iTunes.

posted @ 2013-08-27 17:15  如来藏  阅读(166)  评论(0编辑  收藏  举报