Mailing Lists: Apple Mailing Lists

Image of Mac OS face in stamp
 
[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

Core Data MOM configurations and renaming...



Hi - I'm having some problems with MOM configurations. I have been playing about with some data models and have duplicated and renamed one. When I initialise the MOM using the datamodel name I get results that don't make sense. Here's a snippet of my code:

NSURL* dataDumpURL = [[NSURL alloc] initFileURLWithPath:[bundle pathForResource:@"OptDataDump" ofType:@"mom"]];
dataDumpMOM = [[NSManagedObjectModel alloc] initWithContentsOfURL:dataDumpURL];
NSArray *temp = [dataDumpMOM configurations];


My data model in XCode has the filename OptDataDump.xcdatamodel. The dataDump MOM is initialised with no errors, using the URL created on the first line ('OptDataDump'). Yet when I poll the MOM and get it to put it's configurations into an array (the last line of the code) I get a string value 'DataDump'.

This 'OptDataDump' was copied and renamed from 'DataDump', but I can't figure out why the MOM is getting the old configuration name from - where else is it stored apart from the filename ?

Thanks for any help you can give.

- Martin
_______________________________________________

Cocoa-dev mailing list (email@hidden)

Please do not post admin requests or moderator comments to the list.
Contact the moderators at cocoa-dev-admins(at)lists.apple.com

Help/Unsubscribe/Update your Subscription:
http://lists.apple.com/mailman/options/cocoa-dev/email@hidden

This email sent to email@hidden


Visit the Apple Store online or at retail locations.
1-800-MY-APPLE

Contact Apple | Terms of Use | Privacy Policy

Copyright © 2007 Apple Inc. All rights reserved.