Path: utzoo!utgpu!jarvis.csri.toronto.edu!cs.utexas.edu!swrinde!zaphod.mps.ohio-state.edu!tut.cis.ohio-state.edu!pt.cs.cmu.edu!rochester!cornell!wayner From: wayner@svax.cs.cornell.edu (Peter Wayner) Newsgroups: comp.sys.mac.programmer Subject: The Prefered Way to Refer to Files... Keywords: File Manager Message-ID: <38534@cornell.UUCP> Date: 12 Mar 90 22:20:46 GMT Sender: nobody@cornell.UUCP Reply-To: wayner@cs.cornell.edu (Peter Wayner) Distribution: comp Organization: Cornell Univ. CS Dept, Ithaca NY Lines: 34 I've been coding up an application which needs to keep a list of files and their locations on the disk. This list needs to be stable from boot to boot and even between restores from backup. There are several ways this can be done: 1) Full Path name 2) file name and DirId Tech Note #240 something says that path names are not as robust as directory ids because directory ids are preserved when directories are moved. On the other hand, it admits that restoring a file from backups will probably not preserve Directory Id's. My questions are; Are there any other problems with pathnames? How can I convert a DirId into a vRef which I can then use with SFOpen? Or more generally, how can I open a file with a name and a DirId? What about System 7.0? The tech note mentions that file id numbers will be the best when System 7.0 comes around because they will be stable even after renaming. Thanks to every kind hearted and knowledgable soul on the net, Peter Wayner (wayner@cs.cornell.edu) Peter Wayner Department of Computer Science Cornell Univ. Ithaca, NY 14850 EMail:wayner@svax.cs.cornell.edu Office: 607-255-9202 Home: 119 Ferris Place, Ithaca, NY 14850 Phone: 607-277-0785