#include <CallFunction.hpp>
Public Member Functions | |
CallFunction (base::ActionInterface *init_com, boost::shared_ptr< ProgramInterface > foo, ExecutionEngine *p, ExecutionEngine *caller, internal::AssignableDataSource< ProgramInterface * > *v=0, internal::AssignableDataSource< bool > *a=0) | |
base::ActionInterface * | clone () const |
base::ActionInterface * | copy (std::map< const base::DataSourceBase *, base::DataSourceBase * > &alreadyCloned) const |
virtual bool | execute () |
virtual void | readArguments () |
virtual void | reset () |
virtual bool | valid () const |
~CallFunction () | |
Private Member Functions | |
bool | fooDone () |
Private Attributes | |
boost::shared_ptr < ProgramInterface > | _foo |
internal::AssignableDataSource < ProgramInterface * > ::shared_ptr | _v |
bool | isqueued |
bool | maccept |
ExecutionEngine * | mcaller |
base::ActionInterface * | minit |
ExecutionEngine * | mrunner |
An action which calls a FunctionFraph for execution in a ExecutionEngine. Script functions are always executed in the thread of the component.
It is an DataSource such that it can be executed by program scripts.
Definition at line 62 of file CallFunction.hpp.
RTT::scripting::CallFunction::CallFunction | ( | base::ActionInterface * | init_com, |
boost::shared_ptr< ProgramInterface > | foo, | ||
ExecutionEngine * | p, | ||
ExecutionEngine * | caller, | ||
internal::AssignableDataSource< ProgramInterface * > * | v = 0 , |
||
internal::AssignableDataSource< bool > * | a = 0 |
||
) | [inline] |
Create a Command to send a function to a ExecutionEngine.
init_com | The command to execute before sending the function into the processor, in order to initialise it. |
foo | The function to run in the processor. |
p | The target processor which will run the function. |
v | Implementation specific parameter to support copy/clone semantics. |
Definition at line 92 of file CallFunction.hpp.
RTT::scripting::CallFunction::~CallFunction | ( | ) | [inline] |
Definition at line 104 of file CallFunction.hpp.
base::ActionInterface* RTT::scripting::CallFunction::clone | ( | ) | const [inline, virtual] |
The Clone Software Pattern.
Implements RTT::base::ActionInterface.
Definition at line 145 of file CallFunction.hpp.
base::ActionInterface* RTT::scripting::CallFunction::copy | ( | std::map< const base::DataSourceBase *, base::DataSourceBase * > & | alreadyCloned | ) | const [inline] |
Definition at line 151 of file CallFunction.hpp.
virtual bool RTT::scripting::CallFunction::execute | ( | ) | [inline, virtual] |
Execute the functionality of this action.
Implements RTT::base::ActionInterface.
Definition at line 108 of file CallFunction.hpp.
bool RTT::scripting::CallFunction::fooDone | ( | ) | [inline, private] |
Definition at line 80 of file CallFunction.hpp.
virtual void RTT::scripting::CallFunction::readArguments | ( | ) | [inline, virtual] |
This is invoked some time before execute() at a time when the action may read its function arguments.
Implements RTT::base::ActionInterface.
Definition at line 140 of file CallFunction.hpp.
virtual void RTT::scripting::CallFunction::reset | ( | void | ) | [inline, virtual] |
Reset this action. Must be used after execute() failed.
Reimplemented from RTT::base::ActionInterface.
Definition at line 130 of file CallFunction.hpp.
virtual bool RTT::scripting::CallFunction::valid | ( | ) | const [inline, virtual] |
Inspect if this action was executed and valid. This method may not be called before execute(). The default implementation returns always true, i.e. after execute(), it was executed. Override this method if it has more complex state semantics.
Reimplemented from RTT::base::ActionInterface.
Definition at line 136 of file CallFunction.hpp.
boost::shared_ptr<ProgramInterface> RTT::scripting::CallFunction::_foo [private] |
_foo contains the exact same pointer as _v->get(), but also serves as a shared_ptr handle for cleanup after clone().
Definition at line 76 of file CallFunction.hpp.
internal::AssignableDataSource<ProgramInterface*>::shared_ptr RTT::scripting::CallFunction::_v [private] |
_v is only necessary for the copy/clone semantics.
Definition at line 71 of file CallFunction.hpp.
bool RTT::scripting::CallFunction::isqueued [private] |
Definition at line 77 of file CallFunction.hpp.
bool RTT::scripting::CallFunction::maccept [private] |
Definition at line 78 of file CallFunction.hpp.
Definition at line 67 of file CallFunction.hpp.
Definition at line 65 of file CallFunction.hpp.
Definition at line 66 of file CallFunction.hpp.