Public Member Functions | Static Public Member Functions | Protected Attributes
OCL::TCP::Command Class Reference

#include <command.hpp>

Inheritance diagram for OCL::TCP::Command:
Inheritance graph
[legend]

List of all members.

Public Member Functions

 Command (std::string name)
const std::string & getName () const
virtual RealCommandgetRealCommand (const std::vector< Command * > &cmds) const =0
virtual bool is (std::string &cmd) const
bool operator!= (const std::string &cmp) const
bool operator< (const Command &cmp) const
bool operator== (const std::string &cmp) const
virtual ~Command ()

Static Public Member Functions

static Commandfind (const std::vector< Command * > &cmds, const std::string &cmp)

Protected Attributes

std::string _name

Detailed Description

Command pattern

Definition at line 91 of file command.hpp.


Constructor & Destructor Documentation

OCL::TCP::Command::Command ( std::string  name)

Definition at line 394 of file command.cpp.

Definition at line 399 of file command.cpp.


Member Function Documentation

Command * OCL::TCP::Command::find ( const std::vector< Command * > &  cmds,
const std::string &  cmp 
) [static]

Find the command with the given name in the vector.

Definition at line 403 of file command.cpp.

const std::string & OCL::TCP::Command::getName ( void  ) const

Get the name of this command.

Definition at line 415 of file command.cpp.

virtual RealCommand* OCL::TCP::Command::getRealCommand ( const std::vector< Command * > &  cmds) const [pure 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.

Implemented in OCL::TCP::RealCommand, and OCL::TCP::AliasCommand.

bool OCL::TCP::Command::is ( std::string &  cmd) const [virtual]

Definition at line 420 of file command.cpp.

bool OCL::TCP::Command::operator!= ( const std::string &  cmp) const

Definition at line 430 of file command.cpp.

bool OCL::TCP::Command::operator< ( const Command cmp) const

Definition at line 435 of file command.cpp.

bool OCL::TCP::Command::operator== ( const std::string &  cmp) const

Compare on name

Definition at line 425 of file command.cpp.


Member Data Documentation

std::string OCL::TCP::Command::_name [protected]

Definition at line 94 of file command.hpp.


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


ocl
Author(s): OCL Development Team
autogenerated on Sat Jun 8 2019 18:48:55