2012-06-14 09:06:06 -04:00
|
|
|
|
|
|
|
#pragma once
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
2013-01-11 23:46:01 -05:00
|
|
|
class cGroup // tolua_export
|
|
|
|
{ // tolua_export
|
|
|
|
public: // tolua_export
|
2012-06-14 09:06:06 -04:00
|
|
|
cGroup() {}
|
|
|
|
~cGroup() {}
|
|
|
|
|
2014-04-18 15:09:44 -04:00
|
|
|
void SetName( const AString & a_Name ) { m_Name = a_Name; } // tolua_export
|
2014-02-05 12:10:08 -05:00
|
|
|
const AString & GetName() const { return m_Name; } // tolua_export
|
2014-04-18 15:09:44 -04:00
|
|
|
void SetColor( const AString & a_Color ) { m_Color = a_Color; } // tolua_export
|
|
|
|
void AddCommand( const AString & a_Command ); // tolua_export
|
|
|
|
void AddPermission( const AString & a_Permission ); // tolua_export
|
2014-02-05 12:10:08 -05:00
|
|
|
void InheritFrom( cGroup* a_Group ); // tolua_export
|
2012-06-14 09:06:06 -04:00
|
|
|
|
2014-02-05 12:10:08 -05:00
|
|
|
typedef std::map< AString, bool > PermissionMap;
|
2012-06-14 09:06:06 -04:00
|
|
|
const PermissionMap & GetPermissions() const { return m_Permissions; }
|
|
|
|
|
2014-02-05 12:10:08 -05:00
|
|
|
void ClearPermission(void);
|
|
|
|
|
|
|
|
typedef std::map< AString, bool > CommandMap;
|
2012-06-14 09:06:06 -04:00
|
|
|
const CommandMap & GetCommands() const { return m_Commands; }
|
|
|
|
|
2013-01-11 23:46:01 -05:00
|
|
|
const AString & GetColor() const { return m_Color; } // tolua_export
|
2012-06-14 09:06:06 -04:00
|
|
|
|
|
|
|
typedef std::list< cGroup* > GroupList;
|
|
|
|
const GroupList & GetInherits() const { return m_Inherits; }
|
|
|
|
private:
|
2014-02-05 12:10:08 -05:00
|
|
|
AString m_Name;
|
|
|
|
AString m_Color;
|
2012-06-14 09:06:06 -04:00
|
|
|
|
|
|
|
PermissionMap m_Permissions;
|
|
|
|
CommandMap m_Commands;
|
|
|
|
GroupList m_Inherits;
|
2013-01-11 23:46:01 -05:00
|
|
|
};// tolua_export
|