OrocosComponentLibrary  2.7.0
Public Member Functions | Static Public Member Functions | Protected Attributes
AliasCommand Class Reference

Another name for a command. More...

#include <command.hpp>

Inheritance diagram for AliasCommand:
Command

List of all members.

Public Member Functions

 AliasCommand (std::string name, std::string alias)
virtual RealCommandgetRealCommand (const std::vector< Command * > &cmds) const
 Return a reference to the object which is really responsible for executing this command.
virtual bool is (std::string &cmd) const
bool operator== (const std::string &cmp) const
 Compare on name.
bool operator!= (const std::string &cmp) const
bool operator< (const Command &cmp) const
const std::string & getName () const
 Get the name of this command.

Static Public Member Functions

static Commandfind (const std::vector< Command * > &cmds, const std::string &cmp)
 Find the command with the given name in the vector.

Protected Attributes

std::string _name

Detailed Description

Another name for a command.

Definition at line 130 of file command.hpp.


Member Function Documentation

RealCommand * getRealCommand ( const std::vector< Command * > &  cmds) const [virtual]

Return a reference to the object which is really responsible for executing this command.

This enables multiple names for the same command. Return 0 if no such command is founded.

Implements Command.

Definition at line 445 of file command.cpp.

References Command::find(), and Command::getRealCommand().


The documentation for this class was generated from the following files: