1 #ifndef CLASSES_AREXX_H 2 #define CLASSES_AREXX_H 3 4 /* 5 arexx.class definitions (V45) 6 7 Copyright © 2002 The MorphOS Development Team, All Rights Reserved. 8 */ 9 10 #ifndef EXEC_MEMORY_H 11 # include <exec/memory.h> 12 #endif 13 14 #ifndef DOS_DOS_H 15 # include <dos/dos.h> 16 #endif 17 18 #ifndef DOS_RDARGS_H 19 # include <dos/rdargs.h> 20 #endif 21 22 #ifndef REXX_STORAGE_H 23 # include <rexx/storage.h> 24 #endif 25 26 #ifndef REXX_RXSLIB_H 27 # include <rexx/rxslib.h> 28 #endif 29 30 #ifndef REXX_ERRORS_H 31 # include <rexx/errors.h> 32 #endif 33 34 #ifndef INTUITION_CLASSES_H 35 # include <intuition/classes.h> 36 #endif 37 38 #ifndef INTUITION_CLASSUSR_H 39 # include <intuition/classusr.h> 40 #endif 41 42 #ifndef UTILITY_HOOKS_H 43 # include <utility/hooks.h> 44 #endif 45 46 #ifndef REACTION_REACTION_H 47 # include <reaction/reaction.h> 48 #endif 49 50 #pragma pack(2) 51 52 53 /* Tags supported by arexx.class */ 54 55 #define AREXX_Dummy (REACTION_Dummy + 0x30000) 56 #define AREXX_HostName (AREXX_Dummy + 1) 57 #define AREXX_DefExtension (AREXX_Dummy + 2) 58 #define AREXX_Commands (AREXX_Dummy + 3) 59 #define AREXX_ErrorCode (AREXX_Dummy + 4) 60 #define AREXX_SigMask (AREXX_Dummy + 5) 61 #define AREXX_NoSlot (AREXX_Dummy + 6) 62 #define AREXX_ReplyHook (AREXX_Dummy + 7) 63 #define AREXX_MsgPort (AREXX_Dummy + 8) 64 65 66 /* Possible error result codes */ 67 68 #define RXERR_NO_COMMAND_LIST (1L) 69 #define RXERR_NO_PORT_NAME (2L) 70 #define RXERR_PORT_ALREADY_EXISTS (3L) 71 #define RXERR_OUT_OF_MEMORY (4L) 72 73 74 /* Typo-correction. Don't use! */ 75 76 #define AREXX_DefExtention AREXX_DefExtension 77 78 79 /* Methods supported by arexx.class */ 80 81 #define AM_HANDLEEVENT (0x590001) 82 #define AM_EXECUTE (0x590002) 83 #define AM_FLUSH (0x590003) 84 85 86 /* AM_EXECUTE message */ 87 88 struct apExecute 89 { 90 ULONG MethodID; 91 STRPTR ape_CommandString; 92 STRPTR ape_PortName; 93 LONG *ape_RC; 94 LONG *ape_RC2; 95 STRPTR *ape_Result; 96 BPTR ape_IO; 97 }; 98 99 100 /* An array of these structures must be passed at object-creation */ 101 102 struct ARexxCmd 103 { 104 STRPTR ac_Name; 105 UWORD ac_ID; 106 107 VOID (*ac_Func)(VOID); /* VOID ac_Func(struct ARexxCmd *A0, struct RexxMsg *A1) */ 108 109 STRPTR ac_ArgTemplate; 110 ULONG ac_Flags; 111 ULONG *ac_ArgList; 112 LONG ac_RC; 113 LONG ac_RC2; 114 STRPTR ac_Result; 115 }; 116 117 118 #pragma pack() 119 120 #endif /* CLASSES_AREXX_H */