/* * NDResourceFork.h * AppleScriptObjectProject * * Created by nathan on Wed Dec 05 2001. * Copyright (c) 2001 Nathan Day. All rights reserved. */ #import #import @interface TKResourceFile : NSObject { ResFileRefNum fileReference; } + (id)resourceForkForReadingAtURL:(NSURL *)aURL; + (id)resourceForkForWritingAtURL:(NSURL *)aURL; + (id)resourceForkForReadingAtPath:(NSString *)aPath; + (id)resourceForkForWritingAtPath:(NSString *)aPath; - (OSErr)changeResource:(short)anID forData:(NSData *)aData forType:(ResType)aType; - (id)initForReadingAtURL:(NSURL *)aURL; - (id)initForWritingAtURL:(NSURL *)aURL; - (id)initForReadingAtPath:(NSString *)aPath; - (id)initForWritingAtPath:(NSString *)aPath; - (id)initForPermission:(char)aPermission AtURL:(NSURL *)aURL; - (id)initForPermission:(char)aPermission AtPath:(NSString *)aPath; - (NSData *)dataForType:(ResType)aType ID:(short)anID; - (OSErr)addData:(NSData *)aData type:(ResType)aType Id:(short)anID name:(NSString *)aName attributes: (ResAttributes)attributes; - (NSData *)dataForType:(ResType)aType Index:(short)anIndex; - (OSErr)closeFile; - (OSErr)removeType:(ResType)aType Id:(short)anID; - (short)count:(ResType)aType; - (short)resId:(ResType)aType Index:(short)anIndex; - (id)resName:(ResType)aType Index:(short)anIndex; - (OSErr)updateRes; -(TKEndianness)endiannessOfResourceFile; -(void)setEndiannessOfResourceFile:(TKEndianness)endianness; @end