Re: Best Way to Access Separate Core Data Document
Re: Best Way to Access Separate Core Data Document
- Subject: Re: Best Way to Access Separate Core Data Document
- From: mmalcolm crawford <email@hidden>
- Date: Sat, 21 May 2005 22:27:41 -0700
On May 21, 2005, at 10:05 PM, mmalcolm crawford wrote:
addPersistentStoreWithType:configuration:URL:options:error:
You may care to ensure it's read-only:
NSPersistentStoreCoordinator *psc = [[self managedObejctContext]
persistentStoreCoordinator];
NSDictionary *readOnlyOption =
[NSDictionary dictionaryWithObject:[NSNumber numberWithBool:YES]
forKey:NSReadOnlyPersistentStoreOption];
NSError *error = nil;
sharedStore = [psc addPersistentStoreWithType:NSXMLStoreType
configuration:nil // or custom config
URL:sharedStoreURL
options:readOnlyOption
error:&error];
although it shouldn't strictly be necessary if the application logic
is correct...
mmalc
_______________________________________________
Do not post admin requests to the list. They will be ignored.
Cocoa-dev mailing list (email@hidden)
Help/Unsubscribe/Update your Subscription:
This email sent to email@hidden