• 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: Changing a filename while the FSRef is in use
[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

Re: Changing a filename while the FSRef is in use


  • Subject: Re: Changing a filename while the FSRef is in use
  • From: "M. Uli Kusterer" <email@hidden>
  • Date: Sun, 8 Feb 2004 12:58:25 +0100

At 19:05 Uhr +0800 08.02.2004, ruffnex wrote:
Given a download path and filename, I create a FSRef and pass to a 3rd party routine which writes data to the file. In Finder, I can move this growing file, rename it, and the data continues to be written correctly.

Is this use of an Alias? Or something that is supported by Carbon FileManager?

I think as long as you have the file open for reading/writing, it will always point to the same file, even when it is moved or renamed. aka "it just works".

Alias records are useful in the case where the file is closed and you want to keep a less fragile reference to it around even when the file is closed, your app is no longer running, or the computer will be restarted before you refer to the file again. I.e. if you save references to files in your NSUserDefaults, it'd be a good idea to do so as an alias (e.g. using the great BDAlias class).
--
Cheers,
M. Uli Kusterer
------------------------------------------------------------
"The Witnesses of TeachText are everywhere..."
http://www.zathras.de
_______________________________________________
cocoa-dev mailing list | email@hidden
Help/Unsubscribe/Archives: http://www.lists.apple.com/mailman/listinfo/cocoa-dev
Do not post admin requests to the list. They will be ignored.
  • Follow-Ups:
    • Re: Changing a filename while the FSRef is in use
      • From: ruffnex <email@hidden>
References: 
 >Changing a filename while the FSRef is in use (From: ruffnex <email@hidden>)

  • Prev by Date: Changing a filename while the FSRef is in use
  • Next by Date: Re: Anyone have experience coding software updating?
  • Previous by thread: Changing a filename while the FSRef is in use
  • Next by thread: Re: Changing a filename while the FSRef is in use
  • Index(es):
    • Date
    • Thread