简体   繁体   中英

Best practice to deliver Core Data App with content?

Hey guys,
what would you say is the best way to ship initial data with an Core Data iOS App?

Is it maybe to once run the app, store the data and then insert the datafile in the build? There must be a better way..

I have had good experiences with loading the data into a sqlite backing in the simulator, and then bundling the resulting sqlite file with the app.

Especially for bigger datasets, first-run filling of the database is not really an option.

I've been toying around with the same problem myself, recently; and what I opted for was to store the data in the app in some easily parsable (for me) format, and parse and incorporate it on first run.

The technical post webpages of this site follow the CC BY-SA 4.0 protocol. If you need to reprint, please indicate the site URL or the original address.Any question please contact:yoyou2525@163.com.

 
粤ICP备18138465号  © 2020-2024 STACKOOM.COM