iOS - Library/Cache - Database question
Hello there,
Some time ago I've read on this forum that the correct directory to use on iOS for storing data is Library/Cache and since then I've fixed my app to use that directory.
Here it is the link to an article written by "our" Saumitra:
http://www.saumitrabhave.com/2011/11/air-ios-solving-apps-must-follow-ios.html
My app has 2 db files (and some xml files).
The struct looks like this:
[root] my main app
├──data
│ └──dbtemplates (this dir contains my two db files)
└──xml
├──en (this dir contains english localization)
└──it (this dir contains italian localization)
When my app starts, it copies these 2 db files in Library/Cache directory and then the app fills them with data generated on the fly: from that moment my app will use these two new databases for reading and saving datas.
My questions are:
1) With this struct, is it true that my app won't be rejected by Apple? (I mean with data/dbtemplates, xml/it and xml/en subdirectories)
2) Is the Library/Cache the right directory to copy my new db in?
3) If Apple accepts my app, sooner or later I will develop an update to my app: in that case, if the user has not uninstalled my app, when he updates the app from the apple store, the db files that I stored in Library/Cache won't be deleted from the update process, true?
Unilt today I was pretty sure that the answers to my questions were "yes", "yes" and "yes" but today I've spoken with a friend of mine that told me that I need also to flag my dbfiles as "do not backup" and the only wat to accomplish this is to use a native extension:
http://www.jampot.ie/ane/ane-ios-data-storage-set-donotbackup-attribute-for-ios5-native-extension/
Can someone clear my doubts?
Thanks in advance
