Base class for running concurrent navigation tasks. More...
#include <abstract_execution_base.h>
Public Member Functions | |
AbstractExecutionBase (const std::string &name) | |
virtual bool | cancel () |
Cancel the plugin execution. More... | |
const std::string & | getMessage () const |
Gets the current plugin execution message. More... | |
const std::string & | getName () const |
Returns the name of the corresponding plugin. More... | |
uint32_t | getOutcome () const |
Gets the current plugin execution outcome. More... | |
void | join () |
virtual void | postRun () |
Optional implementation-specific cleanup function, called right after execution. More... | |
virtual void | preRun () |
Optional implementation-specific setup function, called right before execution. More... | |
virtual void | reconfigure (MoveBaseFlexConfig &_cfg) |
Optional implementaiton-specific configuration function. More... | |
virtual bool | start () |
virtual void | stop () |
boost::cv_status | waitForStateUpdate (boost::chrono::microseconds const &duration) |
virtual | ~AbstractExecutionBase () |
Protected Member Functions | |
virtual void | run () |
Protected Attributes | |
bool | cancel_ |
flag for canceling controlling More... | |
boost::condition_variable | condition_ |
condition variable to wake up control thread More... | |
std::string | message_ |
the last received plugin execution message More... | |
std::string | name_ |
the plugin name; not the plugin type! More... | |
uint32_t | outcome_ |
the last received plugin execution outcome More... | |
boost::thread | thread_ |
the controlling thread object More... | |
Base class for running concurrent navigation tasks.
The class uses a dedicated thread to run potentially long-lasting jobs. The user can use waitForStateUpdate to get notification about the progress of the said job.
Definition at line 57 of file abstract_execution_base.h.
mbf_abstract_nav::AbstractExecutionBase::AbstractExecutionBase | ( | const std::string & | name | ) |
Definition at line 43 of file src/abstract_execution_base.cpp.
|
virtual |
Definition at line 47 of file src/abstract_execution_base.cpp.
|
inlinevirtual |
Cancel the plugin execution.
Reimplemented in mbf_abstract_nav::AbstractPlannerExecution, mbf_abstract_nav::AbstractControllerExecution, mbf_abstract_nav::AbstractRecoveryExecution, and DummyExecutionBase.
Definition at line 72 of file abstract_execution_base.h.
const std::string & mbf_abstract_nav::AbstractExecutionBase::getMessage | ( | ) | const |
Gets the current plugin execution message.
Definition at line 94 of file src/abstract_execution_base.cpp.
const std::string & mbf_abstract_nav::AbstractExecutionBase::getName | ( | ) | const |
Returns the name of the corresponding plugin.
Definition at line 99 of file src/abstract_execution_base.cpp.
uint32_t mbf_abstract_nav::AbstractExecutionBase::getOutcome | ( | ) | const |
Gets the current plugin execution outcome.
Definition at line 89 of file src/abstract_execution_base.cpp.
void mbf_abstract_nav::AbstractExecutionBase::join | ( | ) |
Definition at line 76 of file src/abstract_execution_base.cpp.
|
inlinevirtual |
Optional implementation-specific cleanup function, called right after execution.
Definition at line 104 of file abstract_execution_base.h.
|
inlinevirtual |
Optional implementation-specific setup function, called right before execution.
Definition at line 99 of file abstract_execution_base.h.
|
inlinevirtual |
Optional implementaiton-specific configuration function.
Definition at line 109 of file abstract_execution_base.h.
|
inlineprotectedvirtual |
Reimplemented in mbf_abstract_nav::AbstractControllerExecution, mbf_abstract_nav::AbstractPlannerExecution, mbf_abstract_nav::AbstractRecoveryExecution, and DummyExecutionBase.
Definition at line 114 of file abstract_execution_base.h.
|
virtual |
Reimplemented in mbf_abstract_nav::AbstractControllerExecution.
Definition at line 57 of file src/abstract_execution_base.cpp.
|
virtual |
Definition at line 70 of file src/abstract_execution_base.cpp.
boost::cv_status mbf_abstract_nav::AbstractExecutionBase::waitForStateUpdate | ( | boost::chrono::microseconds const & | duration | ) |
Definition at line 82 of file src/abstract_execution_base.cpp.
|
protected |
flag for canceling controlling
Definition at line 123 of file abstract_execution_base.h.
|
protected |
condition variable to wake up control thread
Definition at line 114 of file abstract_execution_base.h.
|
protected |
the last received plugin execution message
Definition at line 129 of file abstract_execution_base.h.
|
protected |
the plugin name; not the plugin type!
Definition at line 132 of file abstract_execution_base.h.
|
protected |
the last received plugin execution outcome
Definition at line 126 of file abstract_execution_base.h.
|
protected |
the controlling thread object
Definition at line 120 of file abstract_execution_base.h.