g2o
|
collection of actions More...
#include <hyper_graph_action.h>
Public Member Functions | |
HyperGraphElementActionCollection (const std::string &name_) | |
constructor. name_ is the name of the action e.g.draw). More... | |
virtual | ~HyperGraphElementActionCollection () |
destructor: it deletes all actions in the pool. More... | |
virtual HyperGraphElementAction * | operator() (HyperGraph::HyperGraphElement *element, Parameters *parameters) |
virtual HyperGraphElementAction * | operator() (const HyperGraph::HyperGraphElement *element, Parameters *parameters) |
redefine this to do the action stuff. If successful, the action returns a pointer to itself More... | |
ActionMap & | actionMap () |
bool | registerAction (HyperGraphElementAction *action) |
bool | unregisterAction (HyperGraphElementAction *action) |
Public Member Functions inherited from g2o::HyperGraphElementAction | |
HyperGraphElementAction (const std::string &typeName_="") | |
virtual | ~HyperGraphElementAction () |
destroyed actions release the memory More... | |
const std::string & | typeName () const |
returns the typeid name of the action More... | |
const std::string & | name () const |
returns the name of an action, e.g "draw" More... | |
void | setTypeName (const std::string &typeName_) |
sets the type on which an action has to operate More... | |
Protected Attributes | |
ActionMap | _actionMap |
Protected Attributes inherited from g2o::HyperGraphElementAction | |
std::string | _typeName |
std::string | _name |
Additional Inherited Members | |
Public Types inherited from g2o::HyperGraphElementAction | |
typedef std::map< std::string, HyperGraphElementAction * > | ActionMap |
collection of actions
collection of actions calls contains homogeneous actions operating on different types all collected actions have the same name and should have the same functionality
Definition at line 113 of file hyper_graph_action.h.
g2o::HyperGraphElementActionCollection::HyperGraphElementActionCollection | ( | const std::string & | name_ | ) |
constructor. name_ is the name of the action e.g.draw).
Definition at line 88 of file hyper_graph_action.cpp.
|
virtual |
destructor: it deletes all actions in the pool.
Definition at line 93 of file hyper_graph_action.cpp.
|
inline |
Definition at line 123 of file hyper_graph_action.h.
Referenced by g2o::HyperGraphActionLibrary::unregisterAction().
|
virtual |
calling functions, they return a pointer to the instance of action in actionMap that was active on element
Reimplemented from g2o::HyperGraphElementAction.
Definition at line 100 of file hyper_graph_action.cpp.
|
virtual |
redefine this to do the action stuff. If successful, the action returns a pointer to itself
Reimplemented from g2o::HyperGraphElementAction.
Definition at line 110 of file hyper_graph_action.cpp.
bool g2o::HyperGraphElementActionCollection::registerAction | ( | HyperGraphElementAction * | action | ) |
inserts an action in the pool. The action should have the same name of the container. returns false on failure (the container has a different name than the action);
Definition at line 119 of file hyper_graph_action.cpp.
References __PRETTY_FUNCTION__, g2o::HyperGraphElementAction::name(), and g2o::HyperGraphElementAction::typeName().
Referenced by g2o::HyperGraphActionLibrary::registerAction().
bool g2o::HyperGraphElementActionCollection::unregisterAction | ( | HyperGraphElementAction * | action | ) |
Definition at line 131 of file hyper_graph_action.cpp.
Referenced by g2o::HyperGraphActionLibrary::unregisterAction().
|
protected |
Definition at line 129 of file hyper_graph_action.h.