![]() |
VR-Forces 5.0.2 Developer's Guide
|
This is a class which maintains a list of string command names and the callback functions that are to be called in response to these commands. An application that reads a command string from the user may pass this string to this manager and it will dispatch to the appropriate registered functions.

Classes | |
| class | DtHelpConsoleCommand |
Public Member Functions | |
| DtConsoleCommandManager () | |
| virtual | ~DtConsoleCommandManager () |
| virtual void | addCommand (DtString commandString, DtConsoleCommand *command) |
| virtual void | removeCommand (DtString commandString) |
| virtual void | removeCommand (DtConsoleCommand *command) |
| virtual bool | runCommand (DtString consoleString) |
| virtual DtString | helpText (const DtString ¶meters) const |
| virtual void | addAlias (DtString aliasString, DtConsoleCommand *command) |
| virtual void | addAlias (DtString aliasString, DtString commandString) |
Static Public Member Functions | |
| static void | cleanup () |
| static DtConsoleCommandManager * | globalConsoleCommandManager () |
Public Attributes | |
| boost::signals2::signal< void()> | signal_globalCommandManagerToBeDestroyed |
Protected Types | |
| typedef std::map< DtString, DtConsoleCommand * > | DtConsoleCommandMap |
Protected Member Functions | |
| virtual void | removeReferencesFromMap (DtConsoleCommandMap &commandMap, DtConsoleCommand *command) |
Protected Attributes | |
| DtConsoleCommandMap | myCommandMap |
| DtConsoleCommandMap | myAliasMap |
| tbb::spin_rw_mutex | myMutex |
| DtHelpConsoleCommand * | myHelpCommand |
Static Protected Attributes | |
| static DtConsoleCommandManager * | theConsoleCommandManager |
Private Member Functions | |
| DtConsoleCommandManager (const DtConsoleCommandManager &orig) | |
| DtConsoleCommandManager & | operator= (const DtConsoleCommandManager &orig) |
|
protected |
|
private |
Not implemented.
| DtConsoleCommandManager::DtConsoleCommandManager | ( | ) |
|
virtual |
|
private |
Not implemented.
|
virtual |
Register a new command with the manager. The userData pointer will be passed into the command function when it is called. Case of commandString will be ignored. Takes ownership of command and will destroy the command when the class is destroyed.
|
virtual |
Adds an additional string which will invoke a command already registered with addCommand().
|
virtual |
Adds an additional string which will invoke a command already registered with addCommand().
|
virtual |
Remove a command from the manager. Case of commandString will be ignored.
|
virtual |
Removes all references to the specified command.
Pass in the string entered on the console to run the command (if any) contained in it. Case is ignored.
Reimplemented in MAKVRinTerra::DtFeaturesDebugger.
Reimplemented in MAKVRinTerra::DtFeaturesDebugger.
|
static |
Cleans up global command manager.
|
static |
|
protectedvirtual |
Used internally. Removes all items that refer to command from commandMap.
| boost::signals2::signal<void ()> DtConsoleCommandManager::signal_globalCommandManagerToBeDestroyed |
|
protected |
|
protected |
|
protected |
|
protected |
|
staticprotected |