Plist vs SQLite和核心数据的rss阅读器类型应用程序? [英] Plist vs SQLite vs Core Data for a rss reader type application?

查看:122
本文介绍了Plist vs SQLite和核心数据的rss阅读器类型应用程序?的处理方法,对大家解决问题具有一定的参考价值,需要的朋友们下面随着小编来一起学习吧!

问题描述

我正在开发一个类似于RSS新闻阅读器的应用程序。我需要一些机制来本地存储解析的XML。我尝试使用Plist,但它很快变得非常复杂,因为应用程序的复杂性增长。

I'm developing an application similar to an RSS news reader. I need some mechanism to store the parsed XML locally. I tried using Plist but it soon became enormously complicated as the complexity of the application grew.

我想知道对于经常需要向设备读/写数据的应用程序,存储数据的最佳方法是什么?

I'd like to know what would be the best method to store data for an application in which one frequently needs to read/write data to the device ?

推荐答案

Plist应该用于一些静态的简单有限的数据需求需求。例如,他们在PickerViews中很好。 SQLite和CoreData提供真正的数据访问和操作,如果数据正在改变,数据完整性。数据模型可以被归一化,并且实体之间保持动态关系。此外,可以使用关系连接执行复杂的查询。

Plist should be used for simple and limited data needs requirements that are somewhat static. They are good in PickerViews for example. SQLite and CoreData offer true data access and manipulation, and if data is changing, data integrity. Data models can be normalized, and dynamic relationships maintained between entities. In addition, complex queries can be performed with relational joins.

我已经发布了我使用SQLite的应用程序,虽然更多的是因为iOS SDK(前核心数据)标准SQL语法使努力减少税收。

I have published applications where I used SQLite, and while more because of iOS SDK (pre-Core Data), the standard SQL syntax made the effort less taxing.

我的最新应用程序,SureSafe Home Inventory完全使用CoreData。 CoreData生成并使用SQLite数据库。核心数据是一层以上的SQLite代码我不得不写在我早期的应用程序。虽然初始的学习曲线可能有点艰难,但它是非常值得的改变!我花了大约2个月的时间阅读一切,玩苹果的示例代码变得有点精通。但它需要处理好的数据库编码的头痛。甚至有数据库模型版本控制,所以如果你以后有升级,你可以添加新的数据库字段和迁移现有的客户数据。

My latest applications, SureSafe Home Inventory completely uses CoreData. CoreData generates and uses a SQLite data base. Core Data is a layer above the SQLite code I had to write in my earlier App. While the initial learning curve can be a bit tough, it is well worth the change over!! I spent maybe 2 months reading everything and playing with Apple sample code to become somewhat proficient. But it takes care of so much of the headache of good database coding. There is even database model versioning, so if you have an upgrade later you can add new db fields and migrate existing customer data.

Long Winded ...但如果你开始新的,去CoreData。我与苹果没有联系。

Long Winded... but if you are starting new, go with CoreData. I have no affiliation with Apple.

Steve S.

这篇关于Plist vs SQLite和核心数据的rss阅读器类型应用程序?的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持IT屋!

查看全文
登录 关闭
扫码关注1秒登录
发送“验证码”获取 | 15天全站免登陆