mirror of
https://github.com/JohnEstropia/CoreStore.git
synced 2026-01-16 22:16:53 +01:00
relax NSManagedObject return types so callers don't need to cast every time
This commit is contained in:
@@ -49,7 +49,7 @@ public protocol CSObjectObserver: class, AnyObject {
|
||||
- parameter object: the `NSManagedObject` instance being observed
|
||||
*/
|
||||
@objc
|
||||
optional func objectMonitor(monitor: CSObjectMonitor, willUpdateObject object: NSManagedObject)
|
||||
optional func objectMonitor(monitor: CSObjectMonitor, willUpdateObject object: AnyObject)
|
||||
|
||||
/**
|
||||
Handles processing right after a change to the observed `object` occurs
|
||||
@@ -59,7 +59,7 @@ public protocol CSObjectObserver: class, AnyObject {
|
||||
- parameter changedPersistentKeys: an `NSSet` of key paths for the attributes that were changed. Note that `changedPersistentKeys` only contains keys for attributes/relationships present in the persistent store, thus transient properties will not be reported.
|
||||
*/
|
||||
@objc
|
||||
optional func objectMonitor(monitor: CSObjectMonitor, didUpdateObject object: NSManagedObject, changedPersistentKeys: Set<String>)
|
||||
optional func objectMonitor(monitor: CSObjectMonitor, didUpdateObject object: AnyObject, changedPersistentKeys: Set<String>)
|
||||
|
||||
/**
|
||||
Handles processing right after `object` is deleted
|
||||
@@ -68,5 +68,5 @@ public protocol CSObjectObserver: class, AnyObject {
|
||||
- parameter object: the `NSManagedObject` instance being observed
|
||||
*/
|
||||
@objc
|
||||
optional func objectMonitor(monitor: CSObjectMonitor, didDeleteObject object: NSManagedObject)
|
||||
optional func objectMonitor(monitor: CSObjectMonitor, didDeleteObject object: AnyObject)
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user