resolving aliases
resolving aliases
- Subject: resolving aliases
- From: Yvon Thoraval <email@hidden>
- Date: Fri, 4 Aug 2006 09:06:49 +0200
Hey all,
i'm from the RubyCocoa side and want to resolve aliases.
for now, i'm able to do that in AppleScript and Perl but not in
CocoaRuby, my goal ))
i've a look at the page <http://developer.apple.com/documentation/
Cocoa/Conceptual/LowLevelFileMgmt/Tasks/ResolvingAliases.html>
basically Mister Apple says :
- convert URL to FSRef ;
- resolve alias ;
- reverse convert FSRef to URL
looks simple ))
however, again from RubyCocoa side, i don't know how to get an FSRef
from an URL
as far s i understood well, this is done by the method (?)
"CFURLGetFSRef(url, &fsRef)"
afterwards i might resolve using "FSResolveAliasFille"
and convert back using "CFURLCreateFromFSRef(NULL, &fsRef);"
i know, also, that HSURL are interchangeable with CFURL.
what i don't know, at all, is the receiver of CFURLGetFSRef ???
i've tried :
fm=OSX::NSFileManager.defaultManager
url=OSX::NSURL.alloc.initFileURLWithPath(alias_file)
fsr=fm.fileSystemRepresentationWithPath(alias_file)
but fsr is (still?) a String... with the same value as alias_file...
the, i'm lost ;-)
Yvon
_______________________________________________
Do not post admin requests to the list. They will be ignored.
Cocoa-dev mailing list (email@hidden)
Help/Unsubscribe/Update your Subscription:
This email sent to email@hidden