#include <PeriodicExecutionContext.h>
Public Member Functions | |
DFPBase (RTC::ExecutionContextHandle_t id) | |
Constructor. | |
virtual | ~DFPBase (void) |
Destructor. | |
virtual void | on_startup (void)=0 |
Pure virtual function to be invoked when ExecutionContext starts. | |
virtual void | on_shutdown (void)=0 |
Pure virtual function to be invoked when ExecutionContext stops. | |
virtual void | on_activated (const ECStates &st)=0 |
Pure virtual function to be invoked when RT-Component is activated. | |
virtual void | on_deactivated (const ECStates &st)=0 |
Pure virtual function to be invoked when RT-Component is deactivated. | |
virtual void | on_aborting (const ECStates &st)=0 |
Pure virtual function to be invoked when RT-Component occurs error. | |
virtual void | on_error (const ECStates &st)=0 |
Pure virtual function to be invoked while RT-Component is in the error state. | |
virtual void | on_reset (const ECStates &st)=0 |
Pure virtual function to be invoked when RT-Component resets. | |
virtual void | on_execute (const ECStates &st)=0 |
Pure virtual function to be periodically invoked while RT-Component is running. | |
virtual void | on_state_update (const ECStates &st)=0 |
Pure virtual function to be periodically invoked while RT-Component is running. | |
virtual void | on_rate_changed (void)=0 |
Pure virtual function to be invoked when when the execution cycles of ExecutionContext is changed. | |
virtual void | worker (void) |
Get the worker to execute the state transition. | |
virtual ExecContextState | get_state (void) |
Get the current state of the target component. | |
Public Attributes | |
ExecutionContextHandle_t | ec_id |
ID of participating ExecutionContext. | |
RTC_Utils::StateMachine < ExecContextState, DFPBase > | m_sm |
The state machine of the target RT-Component to manage. |
DFPBase class.
The abstract class to manage DataFlowParticipant registered in tha participant list.
RTC::PeriodicExecutionContext::DFPBase::DFPBase | ( | RTC::ExecutionContextHandle_t | id | ) | [inline] |
Constructor.
Constructor
id | ID of participating ExecutionContext |
References RTC_Utils::StateHolder< State >::curr, RTC_Utils::StateHolder< State >::next, on_aborting(), on_activated(), on_deactivated(), on_error(), on_execute(), on_reset(), on_state_update(), and RTC_Utils::StateHolder< State >::prev.
virtual RTC::PeriodicExecutionContext::DFPBase::~DFPBase | ( | void | ) | [inline, virtual] |
Destructor.
Destructor
virtual ExecContextState RTC::PeriodicExecutionContext::DFPBase::get_state | ( | void | ) | [inline, virtual] |
Get the current state of the target component.
Get the current state of the target component to manage
virtual void RTC::PeriodicExecutionContext::DFPBase::on_aborting | ( | const ECStates & | st | ) | [pure virtual] |
Pure virtual function to be invoked when RT-Component occurs error.
Pure virtual function to be invoked when the RTC is transiting from the Active state to the Error state in some execution context.
st | The current state of the target RT-Component |
Implemented in RTC::PeriodicExecutionContext::DFP< Object >, and RTC::PeriodicExecutionContext::DFP< OpenRTM::DataFlowComponent_var >.
Referenced by DFPBase().
virtual void RTC::PeriodicExecutionContext::DFPBase::on_activated | ( | const ECStates & | st | ) | [pure virtual] |
Pure virtual function to be invoked when RT-Component is activated.
Pure virtual function to be invoked when the RTC has been activated in the given execution context.
st | The current state of the target RT-Component |
Implemented in RTC::PeriodicExecutionContext::DFP< Object >, and RTC::PeriodicExecutionContext::DFP< OpenRTM::DataFlowComponent_var >.
Referenced by DFPBase().
virtual void RTC::PeriodicExecutionContext::DFPBase::on_deactivated | ( | const ECStates & | st | ) | [pure virtual] |
Pure virtual function to be invoked when RT-Component is deactivated.
Pure virtual function to be invoked when the RTC has been deactivated in the given execution context.
st | The current state of the target RT-Component |
Implemented in RTC::PeriodicExecutionContext::DFP< Object >, and RTC::PeriodicExecutionContext::DFP< OpenRTM::DataFlowComponent_var >.
Referenced by DFPBase().
virtual void RTC::PeriodicExecutionContext::DFPBase::on_error | ( | const ECStates & | st | ) | [pure virtual] |
Pure virtual function to be invoked while RT-Component is in the error state.
If the RTC is in the Error state relative to some execution context when it would otherwise be invoked from that context. This operation shall be invoked in sorted order at the rate of the context instead of DataFlowComponentAction::on_execute and on_state_update.The RTC is transitioning from the Active state to the Error state in some execution context.
st | The current state of the target RT-Component |
Implemented in RTC::PeriodicExecutionContext::DFP< Object >, and RTC::PeriodicExecutionContext::DFP< OpenRTM::DataFlowComponent_var >.
Referenced by DFPBase().
virtual void RTC::PeriodicExecutionContext::DFPBase::on_execute | ( | const ECStates & | st | ) | [pure virtual] |
Pure virtual function to be periodically invoked while RT-Component is running.
This operation will be invoked periodically at the rate of the given execution context as long as the following conditions hold:
st | The current state of the target RT-Component |
Implemented in RTC::PeriodicExecutionContext::DFP< Object >, and RTC::PeriodicExecutionContext::DFP< OpenRTM::DataFlowComponent_var >.
Referenced by DFPBase().
virtual void RTC::PeriodicExecutionContext::DFPBase::on_rate_changed | ( | void | ) | [pure virtual] |
Pure virtual function to be invoked when when the execution cycles of ExecutionContext is changed.
This operation is a notification that the rate of the indicated execution context has changed.
Implemented in RTC::PeriodicExecutionContext::DFP< Object >, and RTC::PeriodicExecutionContext::DFP< OpenRTM::DataFlowComponent_var >.
virtual void RTC::PeriodicExecutionContext::DFPBase::on_reset | ( | const ECStates & | st | ) | [pure virtual] |
Pure virtual function to be invoked when RT-Component resets.
The RTC is in the Error state. An attempt is being made to recover it such that it can return to the Inactive state. If the RTC was successfully recovered and can safely return to the Inactive state, this method shall complete with ReturnCode_t::OK. Any other result shall indicate that the RTC should remain in the Error state.
st | The current state of the target RT-Component |
Implemented in RTC::PeriodicExecutionContext::DFP< Object >, and RTC::PeriodicExecutionContext::DFP< OpenRTM::DataFlowComponent_var >.
Referenced by DFPBase().
virtual void RTC::PeriodicExecutionContext::DFPBase::on_shutdown | ( | void | ) | [pure virtual] |
Pure virtual function to be invoked when ExecutionContext stops.
Pure virtual function to be invoked when given execution context, in which the RTC is participating, has transited from Running to Stopped.
Implemented in RTC::PeriodicExecutionContext::DFP< Object >, and RTC::PeriodicExecutionContext::DFP< OpenRTM::DataFlowComponent_var >.
virtual void RTC::PeriodicExecutionContext::DFPBase::on_startup | ( | void | ) | [pure virtual] |
Pure virtual function to be invoked when ExecutionContext starts.
Pure virtual function to be invoked when given execution context, in which the RTC is participating, has transited from Stopped to Running.
Implemented in RTC::PeriodicExecutionContext::DFP< Object >, and RTC::PeriodicExecutionContext::DFP< OpenRTM::DataFlowComponent_var >.
virtual void RTC::PeriodicExecutionContext::DFPBase::on_state_update | ( | const ECStates & | st | ) | [pure virtual] |
Pure virtual function to be periodically invoked while RT-Component is running.
This operation will be invoked periodically at the rate of the given execution context as long as the following conditions hold:
st | The current state of the target RT-Component |
Implemented in RTC::PeriodicExecutionContext::DFP< Object >, and RTC::PeriodicExecutionContext::DFP< OpenRTM::DataFlowComponent_var >.
Referenced by DFPBase().
virtual void RTC::PeriodicExecutionContext::DFPBase::worker | ( | void | ) | [inline, virtual] |
Get the worker to execute the state transition.
Get the worker that executes the state transition of the target component to manage.
Referenced by RTC::PeriodicExecutionContext::invoke_worker::operator()().
ExecutionContextHandle_t RTC::PeriodicExecutionContext::DFPBase::ec_id |
ID of participating ExecutionContext.
Referenced by RTC::PeriodicExecutionContext::DFP< OpenRTM::DataFlowComponent_var >::on_aborting(), RTC::PeriodicExecutionContext::DFP< OpenRTM::DataFlowComponent_var >::on_activated(), RTC::PeriodicExecutionContext::DFP< OpenRTM::DataFlowComponent_var >::on_deactivated(), RTC::PeriodicExecutionContext::DFP< OpenRTM::DataFlowComponent_var >::on_error(), RTC::PeriodicExecutionContext::DFP< OpenRTM::DataFlowComponent_var >::on_execute(), RTC::PeriodicExecutionContext::DFP< OpenRTM::DataFlowComponent_var >::on_rate_changed(), RTC::PeriodicExecutionContext::DFP< OpenRTM::DataFlowComponent_var >::on_reset(), RTC::PeriodicExecutionContext::DFP< OpenRTM::DataFlowComponent_var >::on_shutdown(), RTC::PeriodicExecutionContext::DFP< OpenRTM::DataFlowComponent_var >::on_startup(), RTC::PeriodicExecutionContext::DFP< OpenRTM::DataFlowComponent_var >::on_state_update(), and RTC::PeriodicExecutionContext::Comp::operator=().
The state machine of the target RT-Component to manage.
Referenced by RTC::PeriodicExecutionContext::DFP< OpenRTM::DataFlowComponent_var >::on_activated(), RTC::PeriodicExecutionContext::DFP< OpenRTM::DataFlowComponent_var >::on_execute(), RTC::PeriodicExecutionContext::DFP< OpenRTM::DataFlowComponent_var >::on_reset(), and RTC::PeriodicExecutionContext::DFP< OpenRTM::DataFlowComponent_var >::on_state_update().