Plist vs SQLite vs Core Data for an application like rss reader?

I am developing an application similar to an RSS feed reader. I need a mechanism to store parsed XML locally. I tried using Plist, but it soon became extremely complex as the complexity of the application grew.

I would like to know what would be the best way to store data for an application that often needs to read / write data to a device?

+4
source share
3 answers

A list should be used for simple and limited data needs that are somewhat static. For example, they are good at PickerViews. SQLite and CoreData provide reliable data access and manipulation, as well as data changes - data integrity. Data models can be normalized, and dynamic relationships are maintained between objects. In addition, complex queries can be performed with relational joins.

I published applications in which I used SQLite, and while more because of the IOS SDK (pre-Core Data), the standard SQL syntax attempted less taxation.

My latest apps, SureSafe Home Inventory makes full use of CoreData. CoreData generates and uses the SQLite database. Core Data is the layer above the SQLite code that I had to write in my previous application. While the initial learning curve may be a little stiff, it's worth the change! I probably spent 2 months reading everything and playing with a sample of Apple code to become somewhat experienced. But he cares so much about the headache of good database coding. There is even a version of the database model versions, so if you have an update later, you can add new db fields and transfer the existing client data.

Long Winded ... but if you are starting a new one, head over to CoreData. I have no connection with Apple.

Steve S.

+3
source

I found that CoreData and SQLite are fairly easy to use, allowing you to use the types of complications that you hinted at. Depending on what you want to keep, one will be better than the other. For what you are doing, I would suggest that SQLite is likely to be better. See these questions for further discussion between them:

+1
source

Using plist is actually the simplest form of the 3 you mentioned. If you plan to store a large amount of data, I would suggest using plist compared to CoreData and SQlite.

In addition, you can upload the XML file to your document directory and parse them accordingly.

0
source

Source: https://habr.com/ru/post/1336366/


All Articles