Re: [Leopard] Core Data model versioning vs. NSPersistentDocument
Re: [Leopard] Core Data model versioning vs. NSPersistentDocument
- Subject: Re: [Leopard] Core Data model versioning vs. NSPersistentDocument
- From: mmalc crawford <email@hidden>
- Date: Wed, 7 Nov 2007 10:59:24 -0800
On Nov 6, 2007, at 9:03 PM, mmalc crawford wrote:
Hmm, no. Generally NSPersistentDocument doesn't seem very happy
with the original implementation. I've created an updated version
that uses a subclass of NSDocumentController to perform the
migration: <http://homepage.mac.com/mmalc/CocoaExamples/controllers.html
>. I still don't think it's ideal, but thus far it seems better
than the original. I'll let you know if it changes significantly
again.
I've "played around" with this a little more. It now does a fair
amount of error checking etc. as well. NSDocumentController does seem
to be the easiest place to deal with this... In particular, it now
checks that you don't already have an existing file at the
destination, an if you do (subject to user acceptance) it deletes it.
Otherwise Core Data would simply append to the existing file.
Feedback would be welcome (please send off-list).
mmalc
_______________________________________________
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:
This email sent to email@hidden