1 //IconFamily depends heavily upon Carbon calls and thus will only work in Mac OS X
2 #ifdef MAC_OS_X_VERSION_10_0
4 #import <Foundation/Foundation.h>
5 #import <Carbon/Carbon.h>
7 @interface
NSString (CarbonFSSpecCreation
)
9 // Fills in the given FSRef struct so it specifies the file whose path is in this string.
10 // If the file doesn't exist, and "createFile" is YES, this method will attempt to create
11 // an empty file with the specified path. (The caller should insure that the directory
12 // the file is to be placed in already exists.)
14 - (BOOL
) getFSRef
:(FSRef
*)fsRef createFileIfNecessary
:(BOOL
)createFile
;
16 // Fills in the given FSSpec struct so it specifies the file whose path is in this string.
17 // If the file doesn't exist, and "createFile" is YES, this method will attempt to create
18 // an empty file with the specified path. (The caller should insure that the directory
19 // the file is to be placed in already exists.)
21 - (BOOL
) getFSSpec
:(FSSpec
*)fsSpec createFileIfNecessary
:(BOOL
)createFile
;
23 //given a Carbon FSRef, get a POSIX-style pathname in an NSString.
24 + (NSString
*)pathForFSRef
:(FSRef
*)object
;