Refactoring terminal routines into TerminalDelegate
[RExecServer.git] / RInterpreter.h
blobf5f93afb4aa33081a237459735c2feb805630c11
1 #import <Cocoa/Cocoa.h>
4 @interface RInterpreter : NSObject {
6 char *readerPrompt;
7 unsigned char *readerBuffer,*readerTemp;
8 int readerBufferLength,readerBufferUsed;
9 int readerAddToHistory;
11 NSLock *evalLock;
13 BOOL configured,suppressOutput,allowTerminal,vend,waiting;
14 NSString *vendName;
15 long bufferSize;
16 NSMutableAttributedString *buffer;
17 NSDictionary *outputTag,*errorTag,*promptTag;
19 NSMutableArray *deviceList;
20 int _argc;
21 char **_argv;
25 id delegate;
27 + (RInterpreter*)sharedInterpreter;
28 - (BOOL)isConfigured;
29 - (void)run;
31 #pragma mark Configuration
32 - (void)setArgv:(char**)argv argc:(int)argc;
34 - (void)setDelegate:(id)delegate;
35 - (id)delegate;
37 - (void)setBufferSize:(long)bufferSize;
38 - (long)bufferSize;
40 - (void)setAllowTerminal:(BOOL)aBool;
41 - (BOOL)allowTerminal;
43 - (void)setVend:(BOOL)aBool;
44 - (BOOL)vend;
46 - (void)setHomePath:(NSString*)aPath;
47 - (NSString*)homePath;
49 - (void)setLocaleIdentifier:(NSString*)aLocale;
50 - (NSString*)localeIdentifier;
53 #pragma mark Interaction Protocol
54 - (NSString*)serverName;
56 - (void)awakeConsole;
57 - (void)evaluateInput:(NSString*)aString;
58 - (NSArray*)devices;
60 #pragma mark Moving Data Between Servers
62 - (NSData*)serializeObjectWithName:(NSString*)anName error:(NSError**)anError;
63 - (BOOL)deserializeObject:(NSData*)anObject withName:(NSString*)aName replace:(BOOL)shouldReplace error:(NSError**)error;
64 - (void)copyObjectWithName:(NSString*)anObject toServer:(NSString*)aServer error:(NSError**)anError;
66 @end