Instance Property


Options used when creating the document’s persistent store.


var persistentStoreOptions: [AnyHashable : Any]? { get set }


By default, this value is nil.

To support automatic migration, you might pass a dictionary like that shown in the following example.

NSDictionary *options = @{
    NSMigratePersistentStoresAutomaticallyOption: @YES,
    NSInferMappingModelAutomaticallyOption: @YES
<#Managed document instance#>.persistentStoreOptions = options;

See Also

Managing the Core Data Stack

var managedObjectContext: NSManagedObjectContext

The document’s managed object context.

var managedObjectModel: NSManagedObjectModel

The document’s managed object model.

var modelConfiguration: String?

A model configuration name to be passed when configuring the persistent store.

func persistentStoreType(forFileType: String) -> String

Returns the Core Data store type for a given document file type.