mirror of
https://github.com/JohnEstropia/CoreStore.git
synced 2026-03-23 01:49:53 +01:00
added tool to convert existing NSManagedObjectModels to the new CoreStoreSchema
This commit is contained in:
@@ -48,6 +48,25 @@ internal extension NSManagedObject {
|
||||
}
|
||||
return nil
|
||||
}
|
||||
|
||||
@nonobjc
|
||||
internal func isEditableInContext() -> Bool? {
|
||||
|
||||
guard let context = self.managedObjectContext else {
|
||||
|
||||
return nil
|
||||
}
|
||||
if context.isTransactionContext {
|
||||
|
||||
return true
|
||||
}
|
||||
if context.isDataStackContext {
|
||||
|
||||
return false
|
||||
}
|
||||
return nil
|
||||
}
|
||||
|
||||
// TODO: test before release (rolled back)
|
||||
// @nonobjc
|
||||
// internal static func cs_swizzleMethodsForLogging() {
|
||||
|
||||
Reference in New Issue
Block a user