On 2012 Sep 01, at 04:20, Martin Hewitson <martin.hewit...@aei.mpg.de> wrote:
> 1) Can one determine the version of a model from it's core data store file > (XML) ? > 2) Can one determine the corresponding version number of the models in Xcode ? If I remember correctly, models are identified by UUIDs. The normal method is to iterate through all the available models you have until you find one for which -[NSManagedObjectModel isConfiguration: compatibleWithStoreMetadata:]. You might learn something from here… https://github.com/jerrykrinock/ClassesObjC/blob/master/SSYPersistentDocumentMultiMigrator.m I think that the UUID itself is in the store's metadata, which you can learn how to dig into here… https://github.com/jerrykrinock/CategoriesObjC/blob/master/NSPersistentDocument%2BSSYMetadata.m > 3) Can one somehow reconstruct (if even by hand) a core data model from a > store file? It may be different with an XML store, but with an sqlite store, you could look at the tables in the store. Tables correspond to entities, etc. A GUI tool like SQLIteManager is handy. _______________________________________________ Cocoa-dev mailing list (Cocoa-dev@lists.apple.com) 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: https://lists.apple.com/mailman/options/cocoa-dev/archive%40mail-archive.com This email sent to arch...@mail-archive.com