- html - 出于某种原因,IE8 对我的 Sass 文件中继承的 html5 CSS 不友好?
- JMeter 在响应断言中使用 span 标签的问题
- html - 在 :hover and :active? 上具有不同效果的 CSS 动画
- html - 相对于居中的 html 内容固定的 CSS 重复背景?
以下是 Apple 的 doc 中将 Core Data 与 Cloudkit 一起使用的要求之一。 :
All relationships must be optional. Due to operation size limitations,relationship changes may not be saved atomically.
Thread 1: Fatal error: Unresolved error Error Domain=NSCocoaErrorDomain Code=134060 "A Core Data error occurred." UserInfo={NSLocalizedFailureReason=CloudKit integration requires that all relationships be optional, the following are not:Some_Managed_Object: some_attribute}, ["NSLocalizedFailureReason": CloudKit integration requires that all relationships be optional, the following are not:Some_Managed_Object: some_attribute]
Account
和
Transfer
.由于转账始终与源账户和目标账户相关联,
Transfer
应该有两个与
Account
的非可选关系.但是由于上述要求,这些关系必须是可选的。
In an eventually consistent distributed system you can never "know"that you have existing data or devices in the cloud. Your applicationwill simply "find out at some point" that this data exists and needsto be designed to handle that
Yup, Core Data CloudKit implements to-many relationships using CRDTs!
Conflict resolution is implemented automatically byNSPersistentCloudKitContainer using a last writer wins merge policy.
最佳答案
Could it be that, to use Cloudkit to sync Core Data, the modal has to be designed to work fine with incomplete relationship?
关于ios - 为什么将 Core Data 与 CloudKit 一起使用时关系必须是可选的?,我们在Stack Overflow上找到一个类似的问题: https://stackoverflow.com/questions/66380409/
我正在尝试用 Swift 编写这段 JavaScript 代码:k_combinations 到目前为止,我在 Swift 中有这个: import Foundation import Cocoa e
我是一名优秀的程序员,十分优秀!