iphone - What's the best way to store static data in an iOS app? -


My app contains a considerable amount of data which it needs to be accessed, but the app will never be changed. Currently I am using this data in JSN files and other applications in SQL Database, but it is not very easy to use in iOS.

I do not want to use the cordata, which provides unnecessary functionality complexity.

Does this propertylist keep a good idea of ​​the data in the file and create an access class? Are there any easy ways to include SQLite without going to the Coratata route?

You can only use plist if the amount of data is relatively small Plist fully memory Is loaded in so that you can actually use it only if you can keep them all plist objects in memory once you need them.

Core data is a learning curve, but in usage it is usually less complex than SQL. In most cases "simple" leads to higher coding of SQL because you end up to whitelist the procedural SQL in the object-oriented API to duplicate the core data functionality. By monitoring retention, you need to manually manage the memory usage of all data every time you want the data, then you write many SQL code. I have updated several applications of core data from SQL and in all cases core data implementation was smaller and cleaner than SQL.

Neither memory nor processor "overhead" is any big core data is highly customized In most cases, hand-tuned with shelf core data is more efficient than SQL. A small sub-optimization in SQL can usually destroy any theoretical advantage.

Of course, if you are already highly skilled in managing CDs in SQL, you can bring the app more quickly into the market by using SQL. However, if you are wondering what is the plan to use on normal platform platforms, then core data is almost always the answer and you should take the time to know it.


Comments