Planet
navi homePPSaboutscreenshotsdownloaddevelopmentforum

Changeset 5190 in orxonox.OLD for trunk/src/lib/shell/shell_command.h


Ignore:
Timestamp:
Sep 18, 2005, 12:09:36 AM (20 years ago)
Author:
bensch
Message:

orxonox/trunk: construct for ShellCommandAlias… have to work some more on this :/

File:
1 edited

Legend:

Unmodified
Added
Removed
  • trunk/src/lib/shell/shell_command.h

    r5189 r5190  
    4343////////////////
    4444class ShellCommandBase;
     45class ShellCommandAlias;
    4546
    4647//! A class to hold all Classes that have (once) registered Commands.
     
    5152  public:
    5253    static const tList<ShellCommandClass>* getCommandClassList() { return ShellCommandClass::commandClassList; };
    53     static tList<const char>* getCommandListOfClass(const char* className);
     54    static bool ShellCommandClass::getCommandListOfClass(const char* className, tList<const char>* stringList);
     55
    5456    static ShellCommandClass* getCommandClass(const char* className);
    5557    static void unregisterAllCommands();
     
    6769    tList<ShellCommandBase>*         commandList;               //!< A list of Commands from this Class
    6870    static tList<ShellCommandClass>* commandClassList;          //!< A list of Classes
     71    static tList<ShellCommandAlias>* aliasesList;               //!< An Alias to A Command. (only for classes with one Instance)
    6972};
    7073
     
    7881
    7982    ShellCommandBase* describe(const char* description);
     83    ShellCommandBase* setAlias(const char* alias);
    8084
    8185    /** @returns the CommandList of the Shell */
     
    312316};
    313317
     318class ShellCommandAlias
     319{
     320  public:
     321    ShellCommandAlias(const char* aliasName, ShellCommandBase* command) { this->aliasName = aliasName; this->command = command; };
     322  private:
     323    const char*         aliasName;
     324    ShellCommandBase*   command;
     325};
     326
     327
    314328#endif /* _SHELL_COMMAND_H */
Note: See TracChangeset for help on using the changeset viewer.