Beginning of new-style AE API; so new there's no code to speak of
[ITFoundation.git] / ITOSAScript.h
index 8462951..547acc6 100755 (executable)
 #import <Foundation/Foundation.h>
 #import <Carbon/Carbon.h>
 
+@class ITOSAComponent;
+
 @interface ITOSAScript : NSObject {
     NSString *_source;
-    unsigned long _scriptSubtype;
+    ITOSAComponent *_component;
+    OSAID _scriptID;
 }
 
 - (id)initWithContentsOfFile:(NSString *)path;
 - (id)initWithSource:(NSString *)source;
 
 - (NSString *)source;
-- (void)setSource:(NSString *)newSource;
-- (unsigned long)scriptSubtype;
-- (void)setScriptSubtype:(unsigned long)newSubtype;
 
-- (NSString *)execute;
+- (ITOSAComponent *)component;
+- (void)setComponent:(ITOSAComponent *)newComponent;
+
+- (BOOL)compileAndReturnError:(NSDictionary **)errorInfo;
+- (BOOL)isCompiled;
+
+- (NSAppleEventDescriptor *)executeAndReturnError:(NSDictionary **)errorInfo;
 
 @end