19#ifndef RTC_EXECUTIONCONTEXTWORKER_H 
   20#define RTC_EXECUTIONCONTEXTWORKER_H 
   22#include <condition_variable> 
   24#include <rtm/idl/RTCSkel.h> 
   28#define NUM_OF_LIFECYCLESTATE 4 
   36  class RTObjectStateMachine;
 
  155    void setECRef(RTC::ExecutionContextService_ptr ref);
 
  314                                           std::chrono::nanoseconds timeout
 
  315                                           = std::chrono::seconds(1),
 
  316                                           long int cycle = 1000);
 
  352                                             std::chrono::nanoseconds timeout
 
  353                                             = std::chrono::seconds(1),
 
  354                                             long int cycle = 1000);
 
  390                                        std::chrono::nanoseconds timeout
 
  391                                        = std::chrono::seconds(1),
 
  392                                        long int cycle = 1000);
 
  423      static const char* 
const st[] = {
 
  429      return state >= RTC::CREATED_STATE && state <= RTC::ERROR_STATE ?
 
 
  569    RTC::ExecutionContextService_var 
m_ref;
 
  589    std::vector<RTC_impl::RTObjectStateMachine*> 
m_comps;
 
  595    using CompItr = std::vector<RTC_impl::RTObjectStateMachine*>::iterator;
 
 
RT component logger class.
 
Logger class.
Definition SystemLogger.h:101
 
RT-Component class.
Definition RTObject.h:93
 
ExecutionContextWorker class.
Definition ExecutionContextWorker.h:112
 
bool isAllNextState(RTC::LifeCycleState state)
 
RTC::ReturnCode_t activateComponent(RTC::LightweightRTObject_ptr comp, RTObjectStateMachine *&rtobj)
Activate an RT-component.
 
CORBA::Boolean isRunning()
Check for ExecutionContext running state.
 
RTC::ReturnCode_t bindComponent(RTC::RTObject_impl *rtc)
Bind the component.
 
RTC::ReturnCode_t start()
Start the ExecutionContext.
 
RTC::ReturnCode_t stopThread()
 
RTC::ReturnCode_t waitResetComplete(RTObjectStateMachine *&rtobj, std::chrono::nanoseconds timeout=std::chrono::seconds(1), long int cycle=1000)
 
RTC::ReturnCode_t removeComponent(RTC::LightweightRTObject_ptr comp)
Remove the RT-Component from participant list.
 
bool isAllCurrentState(RTC::LifeCycleState state)
 
std::mutex m_addedMutex
Definition ExecutionContextWorker.h:592
 
bool m_running
The running state of ExecutionContext true: running, false: stopped .
Definition ExecutionContextWorker.h:580
 
std::mutex m_mutex
Definition ExecutionContextWorker.h:590
 
void invokeWorkerPostDo()
 
RTC::ReturnCode_t startThread()
 
bool isOneOfNextState(RTC::LifeCycleState state)
 
std::mutex m_removedMutex
Definition ExecutionContextWorker.h:594
 
RTC::LifeCycleState getComponentState(RTC::LightweightRTObject_ptr comp)
Get RT-component's state.
 
void setECRef(RTC::ExecutionContextService_ptr ref)
 
RTObjectStateMachine * findComponent(RTC::LightweightRTObject_ptr comp)
 
RTC::ReturnCode_t resetComponent(RTC::LightweightRTObject_ptr comp, RTObjectStateMachine *&rtobj)
Reset the RT-component.
 
RTC::ExecutionContextService_var m_ref
Definition ExecutionContextWorker.h:569
 
RTC::ExecutionContextService_ptr getECRef()
 
RTC::ReturnCode_t stop()
Stop the ExecutionContext.
 
RTC::ReturnCode_t deactivateComponent(RTC::LightweightRTObject_ptr comp, RTObjectStateMachine *&rtobj)
Deactivate an RT-component.
 
virtual ~ExecutionContextWorker()
Destructor.
 
RTC::ReturnCode_t rateChanged()
Execution rate of ExecutionContext chnaged.
 
static const char * getStateString(RTC::LifeCycleState state)
Definition ExecutionContextWorker.h:421
 
bool isOneOfCurrentState(RTC::LifeCycleState state)
 
RTC::ReturnCode_t addComponent(RTC::LightweightRTObject_ptr comp)
Add an RT-component.
 
void updateComponentList()
Updating component list .
 
ExecutionContextWorker()
Default Constructor.
 
std::vector< RTC_impl::RTObjectStateMachine * >::iterator CompItr
Definition ExecutionContextWorker.h:595
 
std::vector< RTC_impl::RTObjectStateMachine * > m_comps
List of the participating component .
Definition ExecutionContextWorker.h:589
 
RTC::Logger rtclog
Logger stream .
Definition ExecutionContextWorker.h:567
 
std::vector< RTC_impl::RTObjectStateMachine * > m_addedComps
Definition ExecutionContextWorker.h:591
 
RTC::ReturnCode_t waitDeactivateComplete(RTObjectStateMachine *&rtobj, std::chrono::nanoseconds timeout=std::chrono::seconds(1), long int cycle=1000)
 
RTC::ReturnCode_t waitActivateComplete(RTObjectStateMachine *&rtobj, std::chrono::nanoseconds timeout=std::chrono::seconds(1), long int cycle=1000)
 
std::vector< RTC_impl::RTObjectStateMachine * > m_removedComps
Definition ExecutionContextWorker.h:593
 
Definition RTObjectStateMachine.h:43
 
Definition ExecutionContextProfile.h:29
 
RTC::LightweightRTObject_var LightweightRTObject_var
Definition ExecutionContextWorker.h:38
 
RTC::LightweightRTObject_ptr LightweightRTObject_ptr
Definition ExecutionContextWorker.h:37