• Open Menu Close Menu
  • Apple
  • Shopping Bag
  • Apple
  • Mac
  • iPad
  • iPhone
  • Watch
  • TV
  • Music
  • Support
  • Search apple.com
  • Shopping Bag

Lists

Open Menu Close Menu
  • Terms and Conditions
  • Lists hosted on this site
  • Email the Postmaster
  • Tips for posting to public mailing lists
Re: file references in CoreData
[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

Re: file references in CoreData


  • Subject: Re: file references in CoreData
  • From: Uli Kusterer <email@hidden>
  • Date: Wed, 29 Oct 2008 18:50:29 +0100

On 29.10.2008, at 09:59, Dirkjan Krijnders wrote:
When using Leopard this is easy: you can store any data type in core data using the 'Transformable' type. Use this to store instances of NSURL that point to your files see
http://developer.apple.com/documentation/Cocoa/Conceptual/CoreData/Articles/cdNSAttributes.html
for more information.


I'd recommend going for an Alias Record instead. URLs are just as fragile as file paths. NDAlias or BDAlias can be serialized to NSData. Keep the path as a backup, but really, recovering files across restarts and tracking them even if the user moves them or the drive gets mounted under a different mount point is a job for Aliases.

Cheers,
-- Uli Kusterer
"The Witnesses of TeachText are everywhere..."
http://www.zathras.de





_______________________________________________

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


References: 
 >file references in CoreData (From: Georg Seifert <email@hidden>)
 >Re: file references in CoreData (From: Dirkjan Krijnders <email@hidden>)

  • Prev by Date: Re: file references in CoreData
  • Next by Date: Re: file references in CoreData
  • Previous by thread: Re: file references in CoreData
  • Next by thread: Re: file references in CoreData
  • Index(es):
    • Date
    • Thread