DekGenius.com
[ Team LiB ] Previous Section Next Section

NSAppleScript Mac OS X 10.2

This class gives clients the ability to load, compile, and run AppleScripts. This class provides methods to initialize the class with either text source code, or with a precompiled script. With an initialized object, clients can compile or execute scripts. The Application Kit declares an extension to the NSAppleScript class that is used to obtain colored source code for a given script.

figs/cocn_1305.gif

@interface NSAppleScript : NSObject <NSCopying>
 // Initializers
   - (id)initWithContentsOfURL:(NSURL *)url error:(NSDictionary **)errorInfo;
   - (id)initWithSource:(NSString *)source;
 // Instance Methods
   - (BOOL)compileAndReturnError:(NSDictionary **)errorInfo;
   - (NSAppleEventDescriptor *)executeAndReturnError:(NSDictionary **)errorInfo;
   - (NSAppleEventDescriptor *)executeAppleEvent:(NSAppleEventDescriptor *)event error:(NSDictionary **)errorInfo;
   - (BOOL)isCompiled;
   - (NSAttributedString *)richTextSource;
   - (NSString *)source;
 // Methods Implementing NSCopying
   - (id)copyWithZone:(NSZone *)zone;

    [ Team LiB ] Previous Section Next Section