NSManagedObject features are now fully supported for CoreStoreObject types. MacOSX 10.12 onwards now support ListMonitors and ObjectMonitors

This commit is contained in:
John Estropia
2017-04-07 20:14:13 +09:00
parent 4aa1a63f9a
commit c0ae129b22
58 changed files with 1172 additions and 803 deletions

View File

@@ -25,7 +25,7 @@ class Palette: NSManagedObject {
get {
let KVCKey = #keyPath(Palette.colorName)
if let colorName = self.accessValueForKVCKey(KVCKey) as? String {
if let colorName = self.getValue(forKvcKey: KVCKey) as? String {
return colorName
}
@@ -49,7 +49,7 @@ class Palette: NSManagedObject {
}
set {
self.setValue(newValue, forKVCKey: #keyPath(Palette.colorName))
self.setValue(newValue, forKvcKey: #keyPath(Palette.colorName))
}
}

View File

@@ -141,7 +141,7 @@ class MigrationsDemoViewController: UIViewController, ListObserver, UITableViewD
// MARK: Private
private typealias ModelMetadata = (label: String, version: String, entityType: AnyClass, migrationChain: MigrationChain)
private typealias ModelMetadata = (label: String, version: String, entityType: NSManagedObject.Type, migrationChain: MigrationChain)
private let models: [ModelMetadata] = [
(