- (NSURL *)URLByDeletingLastPathComponent;
Returns a new NSURL equivelent to the receiver with the last component removed.
Result: A new NSURL+ (NSURL *)URLWithFSRef:(const FSRef *)aFsRef;
Returns a file url for the file refered to by a FSRef.
Result: A NSURL containing a file url.
Name Description aFsRef A pointer to a FSRef.
+ (NSURL *)URLWithFileSystemPathHFSStyle:(NSString *)aHFSString;
Returns a file url for the file refered to by a HFS style path.
Result: A NSURL containing a file url.
Name Description aHFSString A NSString containing a HFS style path.
- (NSString *)fileSystemPathHFSStyle;
Returns a NSString containg a HFS style path (e.g. Macitosh HD:Users:) useful for display purposes.
Result: A new NSString containing a HFS style path for the same file or directory as the receiver.- (BOOL)finderInfoFlags:(UInt16*)aFlags type:(OSType*)aType creator:(OSType*)aCreator;
The bits of the finder info flag are
Name Description kIsOnDesk Files and folders (System 6) kColor Files and folders kIsShared Files only (Applications only)
If clear, the application needs to write to its resource fork, and therefore cannot be shared on a serverkHasNoINITs Files only (Extensions/Control Panels only)
This file contains no INIT resourcekHasBeenInited Files only
Clear if the file contains desktop database resources ('BNDL', 'FREF', 'open', 'kind'...) that have not been added yet. Set only by the FinderkHasCustomIcon Files and folders kIsStationery Files only kNameLocked Files and folders kHasBundle Files only kIsInvisible Files and folders kIsAlias Files only.
Result: Return YES if successful, otherwise NO and the returned values are invalid.
Name Description aFlags Contains finder flags on return. aType Contains finder type on return. aCreator Contains creator on return.
- (NSPoint)finderLocation;
Returns a finder items location within its parent window.
Result: A NSPoint- (BOOL)getFSRef:(FSRef *)aFsRef;
Obtain a FSRef for a file url.
Result: Returns YES if successful, if the method returns NO then aFsRef contains garbage.
Name Description aFsRef A pointer to a FSRef struct, to be filled by the method.
- (BOOL)getFSSpec:(FSSpec *)aFSSpec;
Obtain a FSSpec for a file url.
Result: Returns YES if successful, if the method returns NO then aFSSpec contains garbage.
Name Description aFSSpec A pointer to a FSSpec struct, to be filled by the method.
- (NSURL *)resolveAliasFile;
Returns an file url NSURL refered to by the receveive if the receveive refers to an alias file. If it does not refer to an alias file the a url identical to the receveive is returned.
Result: An file url NSURL.- (BOOL)setFinderInfoFlags:(UInt16)aFlags mask:(UInt16)aMask type:(OSType)aType creator:(OSType)aCreator;
The bits of the finder info flag are
Name Description kIsOnDesk Files and folders (System 6) kColor Files and folders kIsShared Files only (Applications only)
If clear, the application needs to write to its resource fork, and therefore cannot be shared on a serverkHasNoINITs Files only (Extensions/Control Panels only)
This file contains no INIT resourcekHasBeenInited Files only
Clear if the file contains desktop database resources ('BNDL', 'FREF', 'open', 'kind'...) that have not been added yet. Set only by the FinderkHasCustomIcon Files and folders kIsStationery Files only kNameLocked Files and folders kHasBundle Files only kIsInvisible Files and folders kIsAlias Files only.
Result: Returns YES if successful.
Name Description aFlags Finder flags. aMask Mask for Finder flags aType The Finder file type aCreator The application creator code
- (BOOL)setFinderLocation:(NSPoint)aLocation;
Set the location of a finder item within in container.
Result: Returns YES if successful.
Name Description aLocation The location
© 2003 Nathan Day (Last Updated 11/30/2003)