00001
00006 #ifdef CENTUMSHAREDCODE_EXPORTS
00007 #define CENTUMSHAREDCODE_API __declspec(dllexport)
00008 #else
00009 #define CENTUMSHAREDCODE_API __declspec(dllimport)
00010 #endif
00011
00012 #ifndef CENUTUMSHAREDCODE_H
00013 #define CENUTUMSHAREDCODE_H
00014
00015 #include <stdlib.h>
00016 #include <malloc.h>
00017 #include <string.h>
00018 #include <windows.h>
00019 #include <time.h>
00020
00021 #define INST_ALIAS 0x01
00022 #define INST_CREATE 0x02
00023 #define INST_MEMBER 0x03
00024
00025 #define FIND_SCOPE 0x01
00026 #define FIND_THING 0x02
00027 #define FIND_UNDEF 0x03
00028
00029 class CScope;
00030 class CThing;
00031 class CThingStack;
00032 class CStringManager;
00033 class CDefinition;
00034 class CThingArray;
00035
00036 #define EXEC_NORMAL 0x00000000
00037 #define EXEC_RETURN 0x00000001
00038 #define EXEC_EXCEPTION 0x00000002
00039 #define EXEC_MULTIPLERETURN 0x000FFFFF
00040 #define EXEC_RETURNTO 0x00000003
00041 #define EXEC_RETURNFROM 0x00000004
00042
00043
00047 struct ExecutionReturn
00048 {
00049 unsigned long valueofexection;
00050 CThingStack* exception;
00051
00055 ExecutionReturn()
00056 {
00057 valueofexection = EXEC_NORMAL;
00058 exception = (CThingStack*)0;
00059 }
00060 };
00061
00062 #define CTHING_READONLY 0x80000000
00063 #define CTHING_REGISTEREDFUNCTION 0x00000001
00064 #define CTHING_DLLFUNCTION 0x00000002
00065 #define CTHING_UNDEF 0x00000004
00066
00067
00068 #define DATA_TYPE_RAW 0x80000001
00069 #define DATA_TYPE_SIGNED_LONG 0x80000002
00070 #define DATA_TYPE_FLOAT 0x80000003
00071 #define DATA_TYPE_BOOLEAN 0x80000004
00072 #define DATA_TYPE_STRING 0x80000005
00073 #define DATA_TYPE_ARRAY 0x80000006
00074 #define DATA_TYPE_EXTERNAL_FUNCTION 0x80000007
00075 #define DATA_TYPE_DLL_NAME 0x80000008
00076 #define DATA_TYPE_DLL_FUNCTION_NAME 0x80000009
00077 #define DATA_TYPE_DLL_FUNCTION_VALUE 0x8000000A
00078 #define DATA_TYPE_CONSOLE 0x8000000B
00079 #define DATA_TYPE_FILE 0x8000000C
00080 #define DATA_TYPE_SOCKET 0x8000000D
00081 #define DATA_TYPE_CLIENT_CONNECTION 0x8000000E
00082 #define DATA_TYPE_SCRIPT 0x8000000F
00083 #define DATA_TYPE_THREADLIST 0x80000010
00084 #define DATA_TYPE_TIME 0x80000011
00085 #define DATA_TYPE_FILE_STREAM 0x80000011
00086 #define DATA_TYPE_WORD_TYPE 0x80000012
00087 #define DATA_TYPE_SCOPE 0x80000012
00088 #define DATA_TYPE_HWND 0x80000014
00089 #define DATA_TYPE_PYTHON 0x80000015
00090 #define DATA_TYPE_JAVAVM 0x80000016
00091 #define DATA_TYPE_JAVA_CLASS 0x80000017
00092 #define DATA_TYPE_JAVA_OBJECT 0x80000018
00093 #define DATA_TYPE_JAVA_LONG 0x80000019
00094 #define DATA_TYPE_JAVA_METHODID 0x8000001A
00095 #define DATA_TYPE_JAVA_MEMBERID 0x8000001B
00096 #define DATA_TYPE_JAVA_BYTE 0x8000001C
00097 #define DATA_TYPE_JAVA_CHAR 0x8000001D
00098 #define DATA_TYPE_JAVA_SHORT 0x8000001E
00099 #define DATA_TYPE_JAVA_DOUBLE 0x8000001F
00100 #define DATA_TYPE_JAVA_BOOL 0x80000020
00101 #define DATA_TYPE_JAVA_INT 0x80000021
00102 #define DATA_TYPE_JAVA_FLOAT 0x80000022
00103 #define DATA_TYPE_HKEY 0x80000023
00104 #define DATA_TYPE_HANDLE 0x80000024
00105 #define DATA_TYPE_READANDWRITE 0x80000025
00106
00107 class CThing;
00108 class CThingArray;
00109 class CScope;
00110 class IMemory;
00111
00112 class CENTUMSHAREDCODE_API CDllList
00113 {
00114 private:
00115 CDllList* next;
00116 char* name;
00117 HMODULE dllhandle;
00118 public:
00119 CDllList();
00120 ~CDllList();
00121 CDllList* GetWithName(const char* n);
00122 static CDllList* NewDll(const char* n, CDllList* head);
00123 HMODULE GetHandle() const;
00124 };
00125
00126 class CENTUMSHAREDCODE_API CDllManager
00127 {
00128 private:
00129 CDllList* head;
00130 public:
00131 CDllManager();
00132 ~CDllManager();
00133 void Construct();
00134 void Destruct();
00135 HMODULE OpenDll(const char* name);
00136 };
00137
00138 class CENTUMSHAREDCODE_API CThingArray
00139 {
00140 public:
00141 CThing** ar;
00142 unsigned long size;
00143 unsigned long used;
00144
00145 CThingArray();
00146 ~CThingArray();
00147 void Construct();
00148 void Destruct();
00149 void AddCThing(CThing* t);
00150 CThing* ReturnAt(unsigned long i) const;
00151 void AddAt(unsigned long i, CThing* t);
00152 void RemoveAt(unsigned long i);
00153 unsigned long NumberOfThings() const;
00154 };
00155
00156 class CENTUMSHAREDCODE_API PointerArray
00157 {
00158 public:
00159 char** ar;
00160 unsigned long size;
00161 unsigned long used;
00162
00163 PointerArray();
00164 ~PointerArray();
00165 void Construct();
00166 void Destruct();
00167 void AddPointer(char* t);
00168 char* ReturnAt(unsigned long i) const;
00169 void AddAt(unsigned long i, char* t);
00170 void RemoveAt(unsigned long i);
00171 unsigned long NumberOfPointers() const;
00172 };
00173
00174 class CENTUMSHAREDCODE_API Int8Array
00175 {
00176 public:
00177 unsigned __int8* ar;
00178 unsigned long size;
00179 unsigned long used;
00180
00181 Int8Array();
00182 ~Int8Array();
00183 void Construct();
00184 void Destruct();
00185 void AddInt8(unsigned __int8 t);
00186 unsigned __int8 ReturnAt(unsigned long i) const;
00187 void AddAt(unsigned long i, unsigned __int8 t);
00188 void RemoveAt(unsigned long i);
00189 unsigned long NumberOfInt8s() const;
00190 unsigned long Find(unsigned __int8 v) const;
00191 };
00192
00193 class CENTUMSHAREDCODE_API LongArray
00194 {
00195 public:
00196 unsigned long* ar;
00197 unsigned long size;
00198 unsigned long used;
00199
00200 LongArray();
00201 ~LongArray();
00202 void Construct();
00203 void Destruct();
00204 void AddLong(unsigned long t);
00205 unsigned long ReturnAt(unsigned long i) const;
00206 void AddAt(unsigned long i, unsigned long t);
00207 void RemoveAt(unsigned long i);
00208 unsigned long NumberOfLongs() const;
00209 unsigned long Find(unsigned long v) const;
00210 };
00211
00212 class CENTUMSHAREDCODE_API CProcessData
00213 {
00214 public:
00215 long references;
00216
00217 IMemory* manager;
00218 CStringManager* strings;
00219
00220 CScope* globalscope;
00221 unsigned long processid;
00222
00223 HANDLE mutex;
00224 CDllManager dlls;
00225
00226 CThing* undef;
00227 CThing* interpterexception;
00228
00229 void Construct(IMemory* m, CStringManager* s);
00230 void Destruct();
00231 void Finalize();
00232 void SetBasics(CThing* u, CThing* i);
00233 };
00234
00235 CENTUMSHAREDCODE_API ExecutionReturn ExecuteSingleFunction(CProcessData* dat, CThing* function, CThingStack* params, CThingStack* usings);
00236 CENTUMSHAREDCODE_API void AddCProcessDataReference(CProcessData* p);
00237 CENTUMSHAREDCODE_API void ReleaseCProcessData(CProcessData* p);
00238
00239 struct StackObj
00240 {
00241 unsigned long type;
00242 StackObj* next;
00243
00244 union
00245 {
00246 struct
00247 {
00248 unsigned long stroffset;
00249 CThing* objpointer;
00250 } stringref;
00251 struct
00252 {
00253 unsigned long dead_value;
00254 CThing* objpointer;
00255 } bareref;
00256 } data;
00257
00258 };
00259
00260 CENTUMSHAREDCODE_API void ConvertSRefToBRef(StackObj* o);
00261
00262 class CENTUMSHAREDCODE_API CThingStack
00263 {
00264 private:
00265 StackObj* head;
00266
00267 public:
00268 CThingStack();
00269 ~CThingStack();
00270
00271 void Construct();
00272 void Destruct();
00273
00274 void PushBareRef(CThing* objptr);
00275 void PushStrRef(CThing* objptr, unsigned long offset);
00276 void PushStackBlock();
00277 void PushStackObject(StackObj* s);
00278
00279 StackObj* GetTop() const;
00280 StackObj* GetN(unsigned long depth) const;
00281 StackObj* GetFunc();
00282
00283 StackObj* Pop();
00284
00285 void Empty();
00286 bool IsEmpty() const;
00287
00288 void Reverse();
00289
00290 void ConvertStackToBares();
00291 CThingStack* GetASubStack();
00292 CThingStack* GetASubStackUnsafe();
00293 unsigned int NumberOfObjects() const;
00294 };
00295
00296 class CENTUMSHAREDCODE_API CScope
00297 {
00298 public:
00299 long references;
00300
00301 LongArray mynames;
00302 CThingArray myrefs;
00303
00304 CThingStack* params;
00305 CThingStack* usings;
00306
00307 CThingStack localstack;
00308 CThingStack usingsstack;
00309
00310 CThing* currentthing;
00311 unsigned long codeposition;
00312
00313 CScope* caller;
00314 CProcessData* processdata;
00315
00322 unsigned long scopedata[3];
00323 HANDLE mutex;
00324
00325 public:
00326
00327 void Construct(CScope* c, CProcessData* owner);
00328 void Destruct();
00329 };
00330
00331 CENTUMSHAREDCODE_API ExecutionReturn CallFunction(CScope* caller, CThing* func, CThingStack* params, CThingStack* usings);
00332 CENTUMSHAREDCODE_API ExecutionReturn ExecuteByteCode(CScope* scope);
00333 CENTUMSHAREDCODE_API void AddCScopeReference(CScope* scope);
00334 CENTUMSHAREDCODE_API void ReleaseCScope(CScope* scope);
00335
00336
00337 class CENTUMSHAREDCODE_API CStringManager
00338 {
00339 private:
00340 LongArray Originals;
00341 PointerArray NewAddresses;
00342 PointerArray Strings;
00343 char* laststringretrieved;
00344 unsigned long lastoffsetlookedup;
00345
00346 public:
00347 ~CStringManager();
00348
00349 char* RetrieveString(unsigned long number);
00350 char* RetrieveString(unsigned long number) const;
00351 void AddStrings(const char* string, unsigned long length, unsigned long originaloffset);
00352 void AddStrings(const char* string, unsigned long length);
00353 void Destruct();
00354 void Construct();
00355
00356 void RemoveString(unsigned long number);
00357 unsigned long RetrieveOffset(const char* string) const;
00358 };
00359
00360 class CThing;
00361
00362 class CENTUMSHAREDCODE_API CLocal
00363 {
00364 public:
00365 CThingArray localrefs;
00366 PointerArray datumrefs;
00367
00368 CThing* container;
00369
00370
00371 CThingArray destobjects;
00372 LongArray localtierefs;
00373 LongArray desttierefs;
00374 public:
00375 void Construct();
00376 void Destruct();
00377
00378 void AddTypedDataAndLength(unsigned long type, unsigned long length, const void* data);
00379 __int8* GetDataByType(unsigned long type) const;
00380 };
00381
00382 class CENTUMSHAREDCODE_API CDefinition
00383 {
00384 public:
00385 long refcount;
00386
00387 LongArray staticnames;
00388 CThingArray staticrefs;
00389
00390 LongArray localnames;
00391
00392 LongArray localinstantationnames;
00393 Int8Array localinstantationtypes;
00394
00395 unsigned long codelegth;
00396 __int8* code;
00397
00398 CProcessData* ownerprocess;
00399 HANDLE mutex;
00400
00401 public:
00402 void Construct(CProcessData* owner);
00403 void Destruct();
00404 };
00405
00406 class CENTUMSHAREDCODE_API CThing
00407 {
00408 public:
00409 long refcount;
00410 unsigned long flags;
00411
00412 CDefinition* def;
00413 CLocal* local;
00414
00415 CProcessData* ownerprocess;
00416 HANDLE mutex;
00417
00418
00419 CThingArray pointedto;
00420 public:
00421 void Construct(CProcessData* owner);
00422 void Destruct();
00423 };
00424
00425 #define SOBJ_TYPE_BLOCK 1
00426 #define SOBJ_TYPE_SREF 2
00427 #define SOBJ_TYPE_BREF 3
00428 #define SOBJ_NULL ((StackObj*)0)
00429
00430 CENTUMSHAREDCODE_API void FillWithStack(CThingArray* a, CThingStack* s);
00431 CENTUMSHAREDCODE_API void ReleaseAll(CThingArray* a);
00432
00433 CENTUMSHAREDCODE_API CThing* CreateCThing(IMemory* m, CProcessData* p);
00434 CENTUMSHAREDCODE_API CDefinition* CreateCDefinition(IMemory* m, CProcessData* p);
00435 CENTUMSHAREDCODE_API CScope* CreateCScope(IMemory* m, CScope* caller, CProcessData* process);
00436 CENTUMSHAREDCODE_API CLocal* CreateCLocal(IMemory* m);
00437 CENTUMSHAREDCODE_API CThingStack* CreateCThingStack(IMemory* m);
00438 CENTUMSHAREDCODE_API void FinishCScope(CScope* s);
00439
00440 namespace FunctionCalls
00441 {
00442 CENTUMSHAREDCODE_API ExecutionReturn HandleReturnValue(CScope* scope, ExecutionReturn ret);
00443 CENTUMSHAREDCODE_API ExecutionReturn HandleUReturnValue(CScope* scope, ExecutionReturn ret);
00444 CENTUMSHAREDCODE_API void ExtractAndReleaseParamsAndUsings(CScope* scope);
00445 CENTUMSHAREDCODE_API ExecutionReturn MakeARegisteredCall(CThing* func, CScope* scope);
00446 CENTUMSHAREDCODE_API ExecutionReturn MakeADLLCall(CThing* func, CScope* scope);
00447 CENTUMSHAREDCODE_API ExecutionReturn MakeANormalCall(CThing* func, CScope* scope);
00448 CENTUMSHAREDCODE_API ExecutionReturn HandleReturnValueAll(CScope* scope, ExecutionReturn ret, CThingStack* dest);
00449 CENTUMSHAREDCODE_API ExecutionReturn HandleReturnedException(CScope* scope, ExecutionReturn ret);
00450 CENTUMSHAREDCODE_API ExecutionReturn CleanReturnValue(ExecutionReturn ret);
00451 };
00452
00457 class CENTUMSHAREDCODE_API IMemory
00458 {
00459 public:
00465 virtual void* Request(unsigned long size) = 0;
00471 virtual void Free(void* ptr) = 0;
00472 };
00473
00474 class CENTUMSHAREDCODE_API CMemoryTracker : public IMemory
00475 {
00476 protected:
00477 PointerArray listofpointer;
00478 unsigned long numpointers;
00479 public:
00480 CMemoryTracker();
00481 ~CMemoryTracker();
00482
00483
00484 virtual void* Request(unsigned long length);
00485 virtual void Free(void* ptr);
00486
00487
00488 unsigned long GetNumberOfPointers() const;
00489 void FreeAll();
00490 };
00491
00492 class CENTUMSHAREDCODE_API CDefaultMemoryManager : public IMemory
00493 {
00494 public:
00495 virtual void* Request(unsigned long length);
00496 virtual void Free(void* ptr);
00497 };
00498
00499 CENTUMSHAREDCODE_API extern CMemoryTracker def;
00500
00501 namespace StackOperations
00502 {
00503 CENTUMSHAREDCODE_API CThing* StackObjToCThing(StackObj* p);
00504 CENTUMSHAREDCODE_API CThing* StackObjToCThingSafe(const StackObj* p);
00505 CENTUMSHAREDCODE_API void FinishCThingStack(CThingStack* s);
00506 };
00507
00508 namespace ThingManipulation
00509 {
00513 struct SFindThing
00514 {
00515 unsigned long type;
00516 union
00517 {
00518 CScope* scope;
00519 CThing* thing;
00520 } data;
00521
00525 SFindThing()
00526 {
00527 type = FIND_UNDEF;
00528 }
00529 };
00530
00531
00532 CENTUMSHAREDCODE_API ExecutionReturn CreateExceptionReturn(CScope* scope, const char* message);
00533 CENTUMSHAREDCODE_API CThing* FindInScope(CScope* s, unsigned long stringindex, const CStringManager* strings, CThing* newvalue = (CThing*)0, CThing** parent = (CThing**)0, long* name = (long*)0);
00534 CENTUMSHAREDCODE_API CThing* FindInThing(CThing* t, unsigned long stringindex, const CStringManager* strings, CThing* newvalue = (CThing*)0, CThing** parent = (CThing**)0, long* name = (long*)0);
00535 CENTUMSHAREDCODE_API CThing* FindInThingSub(CThing* t, unsigned long stringindex, const CStringManager* strings, CThing* newvalue = (CThing*)0, CThing** parent = (CThing**)0, long* name = (long*)0);
00536 CENTUMSHAREDCODE_API SFindThing FindInScopeSub(CScope* s, unsigned long stringindex, const CStringManager* strings, CThing* newvalue = (CThing*)0, CThing** parent = (CThing**)0, long* name = (long*)0);
00537 CENTUMSHAREDCODE_API SFindThing UniversalFind(SFindThing current, unsigned long stroffset, const CStringManager* strings, CThing* newvalue = (CThing*)0, CThing** parent = (CThing**)0, long* name = (long*)0);
00538 CENTUMSHAREDCODE_API SFindThing UniversalArrayFind(SFindThing current, unsigned long stroffset, const CStringManager* strings, CThingArray* dest, CThing** parent = (CThing**)0, long* name = (long*)0);
00539 CENTUMSHAREDCODE_API CThing* FindInScopeArray(CScope* s, unsigned long stringindex, const CStringManager* strings, CThingArray* dest, CThing** parent = (CThing**)0, long* name = (long*)0);
00540
00541 CENTUMSHAREDCODE_API void ReturnAllTied(CThing* current, unsigned long cname, CThingArray* ta, LongArray* la);
00542
00543 CENTUMSHAREDCODE_API CThing* ReturnDestructor(const CThing* t);
00544 CENTUMSHAREDCODE_API CThing* ReturnConstructor(const CThing* t);
00545
00546 CENTUMSHAREDCODE_API CThing* BuildFromDef(CDefinition* def, CScope* scope, CThingStack* params, CThingStack* usings, CThing* owner);
00547 CENTUMSHAREDCODE_API CThing* BuildFromString(const char* str, CScope* scope, CThingStack* params, CThingStack* usings, CThing* owner);
00548 CENTUMSHAREDCODE_API void MakeEqual(CThing* dest, CThing* source);
00549 CENTUMSHAREDCODE_API void CallConstructor(CThing* ret, CScope* scope, CThingStack* params, CThingStack* usings);
00550 CENTUMSHAREDCODE_API void CallDestructor(CThing* thing);
00551 CENTUMSHAREDCODE_API char* GetData(const CThing* t, unsigned long type);
00552 CENTUMSHAREDCODE_API void AddData(CThing* t, unsigned long type, unsigned long length, const char* data);
00553
00554 CENTUMSHAREDCODE_API long GetLong(const CThing* t, long def = 0);
00555 CENTUMSHAREDCODE_API float GetFloat(const CThing* t, float def = 0.0);
00556 CENTUMSHAREDCODE_API char* GetString(const CThing* t, char* def = (char*)0);
00557 CENTUMSHAREDCODE_API bool HasLong(const CThing* t);
00558 CENTUMSHAREDCODE_API void RemoveData(CThing* t, unsigned long type);
00559
00560
00561 CENTUMSHAREDCODE_API bool HasDataType(const CThing* t, unsigned long type);
00562 CENTUMSHAREDCODE_API unsigned long GetDataLength(const CThing* t, unsigned long type);
00563
00564 CENTUMSHAREDCODE_API CThing* ReplaceAndReturn(CThingArray* refs, unsigned long index, CThing* rep);
00565 CENTUMSHAREDCODE_API CThing* ReplaceAndReturnGC(CThingArray* refs, unsigned long index, CThing* rep, CThing* from);
00566 };
00567
00568 typedef ExecutionReturn (*ExternalCall) (unsigned long, CScope*, CThingStack*, CThingStack*);
00569
00570 namespace bytecodes
00571 {
00572 CENTUMSHAREDCODE_API ExecutionReturn CallFunction(CScope* scope);
00573 CENTUMSHAREDCODE_API ExecutionReturn CallUFunction(CScope* scope);
00574 CENTUMSHAREDCODE_API ExecutionReturn Equality(CScope* scope);
00575 CENTUMSHAREDCODE_API ExecutionReturn Alias(CScope* scope);
00576 CENTUMSHAREDCODE_API ExecutionReturn IsA(CScope* scope);
00577 CENTUMSHAREDCODE_API ExecutionReturn PopParameter(CScope* scope);
00578 CENTUMSHAREDCODE_API ExecutionReturn ClearStack(CScope* scope);
00579 CENTUMSHAREDCODE_API ExecutionReturn StackBlock(CScope* scope);
00580 CENTUMSHAREDCODE_API ExecutionReturn UStackBlock(CScope* scope);
00581 CENTUMSHAREDCODE_API ExecutionReturn ClearUStack(CScope* scope);
00582 CENTUMSHAREDCODE_API ExecutionReturn Return(CScope* scope);
00583 CENTUMSHAREDCODE_API ExecutionReturn ThrowException(CScope* scope);
00584 CENTUMSHAREDCODE_API ExecutionReturn PushParameterN(CScope* scope, unsigned __int16 n);
00585 CENTUMSHAREDCODE_API ExecutionReturn PushUsingN(CScope* scope, unsigned __int16 n);
00586 CENTUMSHAREDCODE_API ExecutionReturn PushParameterNU(CScope* scope, unsigned __int16 n);
00587 CENTUMSHAREDCODE_API ExecutionReturn PushUsingNU(CScope* scope, unsigned __int16 n);
00588 CENTUMSHAREDCODE_API ExecutionReturn MultipleReturn(CScope* scope, unsigned __int16 n);
00589 CENTUMSHAREDCODE_API ExecutionReturn PushCThingS(CScope* scope, unsigned long index);
00590 CENTUMSHAREDCODE_API ExecutionReturn PushCThingU(CScope* scope, unsigned long index);
00591 CENTUMSHAREDCODE_API ExecutionReturn Instantiate(CScope* scope);
00592 CENTUMSHAREDCODE_API ExecutionReturn PushParams(CScope* scope);
00593 CENTUMSHAREDCODE_API ExecutionReturn PushUsings(CScope* scope);
00594 CENTUMSHAREDCODE_API ExecutionReturn PushParamsU(CScope* scope);
00595 CENTUMSHAREDCODE_API ExecutionReturn PushUsingsU(CScope* scope);
00596 CENTUMSHAREDCODE_API ExecutionReturn CreateMy(CScope* scope, unsigned long index);
00597 CENTUMSHAREDCODE_API ExecutionReturn ClearBothStacks(CScope* scope);
00598 CENTUMSHAREDCODE_API ExecutionReturn BlockBothStacks(CScope* scope);
00599 CENTUMSHAREDCODE_API ExecutionReturn CopyLocals(CScope* scope);
00600 CENTUMSHAREDCODE_API ExecutionReturn Are(CScope* scope);
00601 CENTUMSHAREDCODE_API ExecutionReturn AddLabel(CScope* scope, unsigned long index);
00602 CENTUMSHAREDCODE_API ExecutionReturn InstantiateU(CScope* scope);
00603 CENTUMSHAREDCODE_API ExecutionReturn LastParam(CScope* scope);
00604 CENTUMSHAREDCODE_API ExecutionReturn Tie(CScope* scope);
00605 CENTUMSHAREDCODE_API ExecutionReturn Untie(CScope* scope);
00606 };
00607
00608 namespace ThingReferences
00609 {
00610 CENTUMSHAREDCODE_API void AddCThingReference(CThing* thing);
00611 CENTUMSHAREDCODE_API void AddDefReference(CDefinition* def);
00612
00613 CENTUMSHAREDCODE_API void ReleaseCThing(CThing* thing);
00614 CENTUMSHAREDCODE_API void ReleaseCDefinition(CDefinition* def);
00615
00616 CENTUMSHAREDCODE_API void AddCThingReferenceGC(CThing* thing, CThing* from);
00617 CENTUMSHAREDCODE_API void ReleaseCThingGC(CThing* thing, CThing* from);
00618 CENTUMSHAREDCODE_API void GarbageCollect(CThing* thing);
00619 };
00620
00621 extern CENTUMSHAREDCODE_API char rootpath[512];
00622
00632 #endif