| Linderdaum Engine: clConsole Class Reference | ![]() |
Virtual console. More...
#include <Console.h>
Classes | |
| class | clCommandsHistory |
| History of console commands. More... | |
Public Types | |
| typedef ::Linderdaum::Utils::clFunctor < void, TYPELIST_1(const LString &) > | clConsoleProc |
Public Member Functions | |
| clConsole () | |
| virtual | ~clConsole () |
| scriptmethod void | AfterConstruction () |
| scriptmethod void | UnpressAllKeys () |
| scriptmethod bool | IsKeyPressed (const int Key) |
| scriptmethod bool | IsKeyPressedAny () |
| scriptmethod void | ExecuteBinding (const int Key, const bool KeyState) |
| scriptmethod void | UnbindAll () |
| scriptmethod void | Bind (const int Key, const LString &Cmd) |
| scriptmethod void | UnBind (const int Key) |
| scriptmethod void | DisplayMessage (const LString &Message, const LConsoleMessageType MSGType) const |
| scriptmethod void | RegisterCommand (const LString &CMDName, const clConsoleProc CmdProc) |
| scriptmethod void | UnRegisterCommand (const LString &CMDName, const clConsoleProc CmdProc) |
| scriptmethod void | SendCommand (const LString &CMDName) |
| scriptmethod void | QueryCommand (const LString &CMDName) |
| scriptmethod LStr::clStringsVector | GetAutocompleteCommand (const LString &CMDName) const |
| scriptmethod void | GetSendCommandResult (LString &Result) const |
| scriptmethod void | SetHUDVisibility (const bool HUDVisible) |
| scriptmethod void | ShowConsole () |
| scriptmethod std::list < sConsoleMessage > * | LockConsoleHistory () |
| scriptmethod void | UnlockConsoleHistory () |
| scriptmethod clCommandsHistory * | GetCommandsHistory () |
| scriptmethod clCVar * | GetVar (const LString &VarName) |
| scriptmethod clCVar * | GetVarDefault (const LString &VarName, const LString &Default) |
| scriptmethod clCVar * | GetVarDefaultFloat (const LString &VarName, float Default) |
| scriptmethod clCVar * | FindVar (const LString &VarName) |
| scriptmethod LString | GetVarValueStr (const LString &VarName, const LString &Default) |
| scriptmethod int | GetVarValueInt (const LString &VarName, const int Default) |
| scriptmethod float | GetVarValueFloat (const LString &VarName, const float Default) |
| scriptmethod bool | GetVarValueBool (const LString &VarName, const bool Default) |
| scriptmethod float | GetTimeVisible () const |
| scriptmethod LString | ExecuteScriptCode (const LString &ScriptCode, bool DisplayResult) |
| scriptmethod clScriptCompiler * | GetScriptCompiler () const |
| scriptmethod void | InitializeScript () |
| explicit script initialization | |
| scriptmethod void | Display (const LString &Message) |
| scriptmethod void | DisplayError (const LString &Message) |
| scriptmethod void | DisplayWarning (const LString &Message) |
| scriptmethod void | DisplayInfoTip (const LString &Message) |
| FWD_EVENT_HANDLER (Event_TIMER) | |
| FWD_EVENT_HANDLER (Event_KEY) | |
| FWD_EVENT_HANDLER (Event_ERROR) | |
Static Public Attributes | |
| static const int | MAX_HISTORY_SIZE = 25 |
Private Types | |
| typedef std::map< LString, clConsoleCommand > | clCommandsList |
| typedef std::map< LString, LString > | clAliasesList |
Private Member Functions | |
| void | ExecuteStatement (const LString &Script) |
| size_t | FindCommandsSeparator (const LString &CMDString) const |
| scriptmethod void | QuitC (const LString &Param) |
| scriptmethod void | ExecC (const LString &Param) |
| scriptmethod void | BindC (const LString &Param) |
| scriptmethod void | AliasC (const LString &Param) |
| scriptmethod void | ToggleConsoleC (const LString &Param) |
| scriptmethod void | MountC (const LString &Param) |
| scriptmethod void | ClearC (const LString &Param) |
| scriptmethod void | VersionC (const LString &Param) |
| scriptmethod void | HelpC (const LString &Param) |
| scriptmethod void | TogglePauseC (const LString &Param) |
| scriptmethod void | ToggleC (const LString &Param) |
| scriptmethod void | SetC (const LString &Param) |
| scriptmethod void | SetPropertyC (const LString &Param) |
| scriptmethod void | ShowC (const LString &Param) |
| scriptmethod void | MenuC (const LString &Param) |
| scriptmethod void | SaveVarsC (const LString &Param) |
| scriptmethod void | RefreshScreenC (const LString &Param) |
| scriptmethod void | SleepC (const LString &Param) |
| scriptmethod void | PrintLogLevelC (const LString &Params) |
| scriptmethod void | SetLogLevelC (const LString &Params) |
Private Attributes | |
| clScriptCompiler * | FScriptCompiler |
| Script compiler. | |
| LString | FSendCommandResult |
| storage for command result | |
| LString | FKeyBindings [256] |
| bool | FKeyPressed [256] |
| clCommandsList | FCommandsList |
| clAliasesList | FAliasesList |
| std::vector< clCVar * > | FCVars |
| std::deque< LString > | FCommandsQueue |
| commands processing | |
| std::list< sConsoleMessage > | FMessagesHistory |
| clCommandsHistory * | FCommandsHistory |
| clMutex | FMessagesHistoryMutex |
| clMutex | FCVarsAccessMutex |
| clMutex | FCommandsQueueMutex |
| bool | FHUDVisible |
| float | FTimeVisible |
| clCVar * | FConsoleHUDFileName |
| clCVar * | FShouldSaveHistory |
Virtual console.
typedef std::map<LString, LString> clConsole::clAliasesList [private] |
typedef std::map<LString, clConsoleCommand> clConsole::clCommandsList [private] |
| typedef ::Linderdaum::Utils::clFunctor<void, TYPELIST_1( const LString& ) > clConsole::clConsoleProc |
| clConsole::clConsole | ( | ) |
| clConsole::~clConsole | ( | ) | [virtual] |
| void clConsole::AfterConstruction | ( | ) | [virtual] |
Reimplemented from iObject.
| void clConsole::AliasC | ( | const LString & | Param | ) | [private] |
| void clConsole::Bind | ( | const int | Key, |
| const LString & | Cmd | ||
| ) |
| void clConsole::BindC | ( | const LString & | Param | ) | [private] |
| void clConsole::ClearC | ( | const LString & | Param | ) | [private] |
| scriptmethod void clConsole::Display | ( | const LString & | Message | ) | [inline] |
| scriptmethod void clConsole::DisplayError | ( | const LString & | Message | ) | [inline] |
| scriptmethod void clConsole::DisplayInfoTip | ( | const LString & | Message | ) | [inline] |
| void clConsole::DisplayMessage | ( | const LString & | Message, |
| const LConsoleMessageType | MSGType | ||
| ) | const |
| scriptmethod void clConsole::DisplayWarning | ( | const LString & | Message | ) | [inline] |
| void clConsole::ExecC | ( | const LString & | Param | ) | [private] |
| void clConsole::ExecuteBinding | ( | const int | Key, |
| const bool | KeyState | ||
| ) |
| LString clConsole::ExecuteScriptCode | ( | const LString & | ScriptCode, |
| bool | DisplayResult | ||
| ) |
| void clConsole::ExecuteStatement | ( | const LString & | Script | ) | [private] |
| size_t clConsole::FindCommandsSeparator | ( | const LString & | CMDString | ) | const [inline, private] |
| clCVar * clConsole::FindVar | ( | const LString & | VarName | ) |
| clConsole::FWD_EVENT_HANDLER | ( | Event_TIMER | ) |
| clConsole::FWD_EVENT_HANDLER | ( | Event_KEY | ) |
| clConsole::FWD_EVENT_HANDLER | ( | Event_ERROR | ) |
| LStr::clStringsVector clConsole::GetAutocompleteCommand | ( | const LString & | CMDName | ) | const |
| scriptmethod clCommandsHistory* clConsole::GetCommandsHistory | ( | ) | [inline] |
| clScriptCompiler * clConsole::GetScriptCompiler | ( | ) | const |
| scriptmethod void clConsole::GetSendCommandResult | ( | LString & | Result | ) | const [inline] |
| scriptmethod float clConsole::GetTimeVisible | ( | ) | const [inline] |
| clCVar * clConsole::GetVar | ( | const LString & | VarName | ) |
| clCVar * clConsole::GetVarDefault | ( | const LString & | VarName, |
| const LString & | Default | ||
| ) |
| bool clConsole::GetVarValueBool | ( | const LString & | VarName, |
| const bool | Default | ||
| ) |
| LString clConsole::GetVarValueStr | ( | const LString & | VarName, |
| const LString & | Default | ||
| ) |
| void clConsole::HelpC | ( | const LString & | Param | ) | [private] |
| void clConsole::InitializeScript | ( | ) |
explicit script initialization
| scriptmethod bool clConsole::IsKeyPressed | ( | const int | Key | ) | [inline] |
| bool clConsole::IsKeyPressedAny | ( | ) |
| std::list< sConsoleMessage > * clConsole::LockConsoleHistory | ( | ) |
| void clConsole::MenuC | ( | const LString & | Param | ) | [private] |
| void clConsole::MountC | ( | const LString & | Param | ) | [private] |
| void clConsole::PrintLogLevelC | ( | const LString & | Params | ) | [private] |
| void clConsole::QueryCommand | ( | const LString & | CMDName | ) |
| void clConsole::QuitC | ( | const LString & | Param | ) | [private] |
| void clConsole::RefreshScreenC | ( | const LString & | Param | ) | [private] |
| void clConsole::RegisterCommand | ( | const LString & | CMDName, |
| const clConsoleProc | CmdProc | ||
| ) |
| void clConsole::SaveVarsC | ( | const LString & | Param | ) | [private] |
| void clConsole::SendCommand | ( | const LString & | CMDName | ) |
| void clConsole::SetC | ( | const LString & | Param | ) | [private] |
| scriptmethod void clConsole::SetHUDVisibility | ( | const bool | HUDVisible | ) | [inline] |
| void clConsole::SetLogLevelC | ( | const LString & | Params | ) | [private] |
| void clConsole::SetPropertyC | ( | const LString & | Param | ) | [private] |
| void clConsole::ShowC | ( | const LString & | Param | ) | [private] |
| void clConsole::ShowConsole | ( | ) |
| void clConsole::SleepC | ( | const LString & | Param | ) | [private] |
| void clConsole::ToggleC | ( | const LString & | Param | ) | [private] |
| void clConsole::ToggleConsoleC | ( | const LString & | Param | ) | [private] |
| void clConsole::TogglePauseC | ( | const LString & | Param | ) | [private] |
| void clConsole::UnBind | ( | const int | Key | ) |
| void clConsole::UnbindAll | ( | ) |
| void clConsole::UnlockConsoleHistory | ( | ) |
| scriptmethod void clConsole::UnpressAllKeys | ( | ) | [inline] |
| void clConsole::UnRegisterCommand | ( | const LString & | CMDName, |
| const clConsoleProc | CmdProc | ||
| ) |
| void clConsole::VersionC | ( | const LString & | Param | ) | [private] |
clAliasesList clConsole::FAliasesList [private] |
clCommandsHistory* clConsole::FCommandsHistory [private] |
clCommandsList clConsole::FCommandsList [private] |
std::deque<LString> clConsole::FCommandsQueue [private] |
commands processing
clMutex clConsole::FCommandsQueueMutex [private] |
clCVar* clConsole::FConsoleHUDFileName [private] |
std::vector<clCVar*> clConsole::FCVars [private] |
clMutex clConsole::FCVarsAccessMutex [private] |
bool clConsole::FHUDVisible [private] |
LString clConsole::FKeyBindings[256] [private] |
bool clConsole::FKeyPressed[256] [private] |
std::list<sConsoleMessage> clConsole::FMessagesHistory [mutable, private] |
clMutex clConsole::FMessagesHistoryMutex [private] |
clScriptCompiler* clConsole::FScriptCompiler [private] |
Script compiler.
LString clConsole::FSendCommandResult [private] |
storage for command result
clCVar* clConsole::FShouldSaveHistory [private] |
float clConsole::FTimeVisible [mutable, private] |
const int clConsole::MAX_HISTORY_SIZE = 25 [static] |