00001 /* 00002 AngelCode Scripting Library 00003 Copyright (c) 2003-2009 Andreas Jonsson 00004 00005 This software is provided 'as-is', without any express or implied 00006 warranty. In no event will the authors be held liable for any 00007 damages arising from the use of this software. 00008 00009 Permission is granted to anyone to use this software for any 00010 purpose, including commercial applications, and to alter it and 00011 redistribute it freely, subject to the following restrictions: 00012 00013 1. The origin of this software must not be misrepresented; you 00014 must not claim that you wrote the original software. If you use 00015 this software in a product, an acknowledgment in the product 00016 documentation would be appreciated but is not required. 00017 00018 2. Altered source versions must be plainly marked as such, and 00019 must not be misrepresented as being the original software. 00020 00021 3. This notice may not be removed or altered from any source 00022 distribution. 00023 00024 The original version of this library can be located at: 00025 http://www.angelcode.com/angelscript/ 00026 00027 Andreas Jonsson 00028 andreas@angelcode.com 00029 */ 00030 00031 00032 // 00033 // as_configgroup.h 00034 // 00035 // This class holds configuration groups for the engine 00036 // 00037 00038 00039 00040 #ifndef AS_CONFIGGROUP_H 00041 #define AS_CONFIGGROUP_H 00042 00043 #include "as_config.h" 00044 #include "as_string.h" 00045 #include "as_array.h" 00046 #include "as_objecttype.h" 00047 #include "as_map.h" 00048 00049 BEGIN_AS_NAMESPACE 00050 00051 class asCConfigGroup 00052 { 00053 public: 00054 asCConfigGroup(); 00055 ~asCConfigGroup(); 00056 00057 // Memory management 00058 int AddRef(); 00059 int Release(); 00060 00061 asCObjectType *FindType(const char *obj); 00062 void RefConfigGroup(asCConfigGroup *group); 00063 00064 bool HasLiveObjects(asCScriptEngine *engine); 00065 void RemoveConfiguration(asCScriptEngine *engine); 00066 00067 int SetModuleAccess(const char *module, bool hasAccess); 00068 bool HasModuleAccess(const char *module); 00069 00070 #ifdef AS_DEBUG 00071 void ValidateNoUsage(asCScriptEngine *engine, asCObjectType *type); 00072 #endif 00073 00074 asCString groupName; 00075 int refCount; 00076 00077 asCArray<asCObjectType*> objTypes; 00078 asCArray<asCScriptFunction*> scriptFunctions; 00079 asCArray<asCGlobalProperty*> globalProps; 00080 #ifdef AS_DEPRECATED 00081 // deprecated since 2009-07-20, 2.17.0 00082 asCArray<int> globalBehaviours; 00083 #endif 00084 asCArray<asCConfigGroup*> referencedConfigGroups; 00085 00086 // Module access 00087 bool defaultAccess; 00088 asCMap<asCString, bool> moduleAccess; 00089 }; 00090 00091 END_AS_NAMESPACE 00092 00093 #endif
1.6.1