00001
00002
00003
00004
00005
00006
00007
00008
00009
00010
00011
00012
00013
00014
00015
00016
00017
00018
00019
00020
00021
00022 #ifndef skiEXECUTABLE_H
00023 #define skiEXECUTABLE_H
00024
00025 #include "skString.h"
00026 #include "skExecutableContext.h"
00027
00028 class CLASSEXPORT skRValueArray;
00029 class CLASSEXPORT skRValue;
00030 class CLASSEXPORT skExecutableIterator;
00031 class CLASSEXPORT skInterpreter;
00032
00033 #ifndef EXCEPTIONS_DEFINED
00034 #include "skScriptError.h"
00035 #endif
00036
00037
00038
00039
00040 const int UNDEFINED_TYPE=0;
00041
00042
00043
00044 const int START_USER_TYPES=10;
00045
00050 class CLASSEXPORT skiExecutable
00051 {
00052 public:
00056 virtual ~skiExecutable() {}
00057
00062 virtual int executableType() const=0;
00066 virtual int intValue() const=0;
00070 virtual bool boolValue() const=0;
00074 virtual Char charValue() const=0;
00078 virtual skString strValue() const=0;
00082 virtual float floatValue() const=0;
00090 virtual bool setValue(const skString& field_name,const skString& attribute,const skRValue& value)=0;
00098 virtual bool setValueAt(const skRValue& array_index,const skString& attribute,const skRValue& value)=0;
00106 virtual bool getValue(const skString& field_name,const skString& attribute,skRValue& value)=0;
00114 virtual bool getValueAt(const skRValue& array_index,const skString& attribute,skRValue& value)=0;
00123 virtual bool method(const skString& method_name,skRValueArray& arguments,skRValue& return_value,skExecutableContext& context)=0;
00127 virtual bool equals(const skiExecutable * other_object) const=0;
00133 virtual skExecutableIterator * createIterator(const skString& qualifier)=0;
00138 virtual skExecutableIterator * createIterator()=0;
00139 };
00140
00141
00142
00143 #define IS_METHOD(s,m) (s==m)
00144 #define IS_GETVALUE(s,v) (s==v)
00145 #define IS_SETVALUE(s,v) (s==v)
00146
00147
00148 #endif