简体   繁体   English

核心数据,iCloud和Cloudkit

[英]Core data, iCloud, and Cloudkit

I am in the planning stage of a new project that will require to use Core Data. 我正处于需要使用Core Data的新项目的计划阶段。 It has these requirements: 1. Be able to access same data across multiple devices. 它具有以下要求:1.能够跨多个设备访问相同的数据。 2. Be able to access same data in offline or online 3. Guarantee data will not be lost. 2.能够离线或在线访问相同的数据。3.确保数据不会丢失。

Couple years ago, I embarked on similar project. 几年前,我开始了类似的项目。 But I had to abandon these features. 但是我不得不放弃这些功能。

Does Core Data with iCloud syncing work well enough for current iOS 7 and 8 to warrant another attempt? 具有iCloud同步功能的Core Data是否可以在当前的iOS 7和8上运行得足够好,值得再次尝试?

If not, I am thinking about using CloudKit and local Core Data storage. 如果没有,我正在考虑使用CloudKit和本地Core Data存储。 But then I will have to write extra code to update both. 但是然后我将不得不编写额外的代码来同时更新两者。

Any suggestions? 有什么建议么?

您可以使用https://github.com/evermeer/EVCloudKitDao这是一个CloudKit库,支持本地缓存(不是Core Data,而是使用NSCoding的文件)

声明:本站的技术帖子网页,遵循CC BY-SA 4.0协议,如果您需要转载,请注明本站网址或者原文地址。任何问题请咨询:yoyou2525@163.com.

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