• 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: How do I get a file reference w/o relying on the path?
[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

Re: How do I get a file reference w/o relying on the path?


  • Subject: Re: How do I get a file reference w/o relying on the path?
  • From: Ken Thomases <email@hidden>
  • Date: Sun, 4 Apr 2010 10:00:59 -0500

On Apr 3, 2010, at 8:31 PM, Jens Alfke wrote:

> Ken, he asked for a reference that wouldn't break if the file were moved or renamed. Neither FSrefs nor URLs have that property.

Yes, they do.

From the link I gave <http://developer.apple.com/mac/library/documentation/cocoa/conceptual/LowLevelFileMgmt/Articles/FileManagementNSURL.html>:

"File reference URLs provide a way to track a file by its ID. This means that the reference is valid even if the file’s name or location in the file system changes."

File reference URLs are new with Snow Leopard.  Check out the release notes and "What's New in Mac OS X: Mac OS X 10.6" to learn about them.

And FSRefs have always had this property.  Adding file reference URLs was essentially a way of allowing URLs to provide analogous functionality as FSRefs.

Regards,
Ken

_______________________________________________

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

  • Follow-Ups:
    • Re: How do I get a file reference w/o relying on the path?
      • From: Jens Alfke <email@hidden>
References: 
 >How do I get a file reference w/o relying on the path? (From: Brad Stone <email@hidden>)
 >Re: How do I get a file reference w/o relying on the path? (From: Ken Thomases <email@hidden>)
 >Re: How do I get a file reference w/o relying on the path? (From: Jens Alfke <email@hidden>)

  • Prev by Date: Finding managed objects by URI representation
  • Next by Date: What patterns did we miss in "Cocoa Design Patterns"?
  • Previous by thread: Re: How do I get a file reference w/o relying on the path?
  • Next by thread: Re: How do I get a file reference w/o relying on the path?
  • Index(es):
    • Date
    • Thread