Go to the documentation of this file.
19 #ifndef RTC_COMPONENTACTIONLISTENER_H
20 #define RTC_COMPONENTACTIONLISTENER_H
27 #include <rtm/idl/RTCSkel.h>
148 static const char* typeString[] =
155 "PRE_ON_DEACTIVATED",
160 "PRE_ON_STATE_UPDATE",
161 "PRE_ON_RATE_CHANGED",
162 "PRE_COMPONENT_ACTION_LISTENER_NUM"
311 static const char* typeString[] =
313 "POST_ON_INITIALIZE",
318 "POST_ON_DEACTIVATED",
323 "POST_ON_STATE_UPDATE",
324 "POST_ON_RATE_CHANGED",
325 "POST_COMPONENT_ACTION_LISTENER_NUM"
329 return typeString[type];
359 ReturnCode_t ret) = 0;
431 static const char* typeString[] =
435 "PORT_ACTION_LISTENER_NUM"
465 virtual void operator()(const ::RTC::PortProfile& pprof) = 0;
538 static const char* typeString[] =
542 "EC_ACTION_LISTENER_NUM"
596 typedef std::pair<PreComponentActionListener*, bool> Entry;
679 std::vector<Entry> m_listeners;
702 typedef std::pair<PostComponentActionListener*, bool> Entry;
786 std::vector<Entry> m_listeners;
810 typedef std::pair<PortActionListener*, bool> Entry;
891 void notify(
const RTC::PortProfile& pprofile);
894 std::vector<Entry> m_listeners;
916 typedef std::pair<ExecutionContextActionListener*, bool> Entry;
1000 std::vector<Entry> m_listeners;
1070 #endif // RTC_COMPONENTACTIONLISTENER_H
PostComponentActionListenerHolder()
Constructor.
@ PRE_ON_STARTUP
Definition: ComponentActionListener.h:61
@ PRE_ON_SHUTDOWN
Definition: ComponentActionListener.h:62
PostComponentActionListener holder class.
Definition: ComponentActionListener.h:700
@ POST_ON_FINALIZE
Definition: ComponentActionListener.h:222
@ PRE_ON_INITIALIZE
Definition: ComponentActionListener.h:59
@ POST_ON_ACTIVATED
Definition: ComponentActionListener.h:225
virtual void operator()(UniqueId ec_id, ReturnCode_t ret)=0
Virtual Callback function.
void addListener(ExecutionContextActionListener *listener, bool autoclean)
Add the listener.
@ EC_ATTACHED
Definition: ComponentActionListener.h:485
virtual ~PreComponentActionListener()
Destructor.
PreComponentActionListenerType
The types of ConnectorDataListener.
Definition: ComponentActionListener.h:57
Mutex class.
Definition: Mutex.h:40
@ POST_ON_ABORTING
Definition: ComponentActionListener.h:227
void notify(UniqueId ec_id)
Notify listeners.
virtual ~PortActionListener()
Destructor.
ExecutionContextActionListenerHolder()
Constructor.
ExecutionContextActionListenerHolder ecaction_[EC_ACTION_LISTENER_NUM]
ExecutionContextActionType listener array The ExecutionContextActionType listener is stored.
Definition: ComponentActionListener.h:1064
@ POST_ON_SHUTDOWN
Definition: ComponentActionListener.h:224
void notify(UniqueId ec_id, ReturnCode_t ret)
Notify listeners.
virtual ~PostComponentActionListener()
Destructor.
@ EC_DETACHED
Definition: ComponentActionListener.h:486
@ PORT_ACTION_LISTENER_NUM
Definition: ComponentActionListener.h:380
@ PRE_ON_STATE_UPDATE
Definition: ComponentActionListener.h:69
void removeListener(PostComponentActionListener *listener)
Remove the listener.
void notify(UniqueId ec_id)
Notify listeners.
@ PRE_ON_RESET
Definition: ComponentActionListener.h:67
@ POST_ON_RATE_CHANGED
Definition: ComponentActionListener.h:232
PreComponentActionListener class.
Definition: ComponentActionListener.h:120
PortActionListener holder class.
Definition: ComponentActionListener.h:808
PortActionListener class.
Definition: ComponentActionListener.h:403
@ POST_ON_STATE_UPDATE
Definition: ComponentActionListener.h:231
@ POST_ON_INITIALIZE
Definition: ComponentActionListener.h:221
static const char * toString(ExecutionContextActionListenerType type)
Convert PreComponentActionListenerType into the string.
Definition: ComponentActionListener.h:536
@ POST_COMPONENT_ACTION_LISTENER_NUM
Definition: ComponentActionListener.h:233
@ PRE_COMPONENT_ACTION_LISTENER_NUM
Definition: ComponentActionListener.h:71
virtual void operator()(UniqueId ec_id)=0
Virtual Callback function.
static const char * toString(PortActionListenerType type)
Convert PreComponentActionListenerType into the string.
Definition: ComponentActionListener.h:429
ExecutionContextActionListener class.
Definition: ComponentActionListener.h:510
virtual ~PostComponentActionListenerHolder()
Destructor.
@ POST_ON_RESET
Definition: ComponentActionListener.h:229
@ EC_ACTION_LISTENER_NUM
Definition: ComponentActionListener.h:487
@ POST_ON_EXECUTE
Definition: ComponentActionListener.h:230
static const char * toString(PreComponentActionListenerType type)
Convert PreComponentActionListenerType into the string.
Definition: ComponentActionListener.h:146
virtual ~ExecutionContextActionListenerHolder()
Destructor.
void addListener(PreComponentActionListener *listener, bool autoclean)
Add the listener.
@ ADD_PORT
Definition: ComponentActionListener.h:378
@ PRE_ON_RATE_CHANGED
Definition: ComponentActionListener.h:70
PortActionListenerHolder portaction_[PORT_ACTION_LISTENER_NUM]
PortActionType listener array The PortActionType listener is stored.
Definition: ComponentActionListener.h:1053
virtual void operator()(const ::RTC::PortProfile &pprof)=0
Virtual Callback function.
void addListener(PostComponentActionListener *listener, bool autoclean)
Add the listener.
void notify(const RTC::PortProfile &pprofile)
Notify listeners.
ComponentActionListeners class.
Definition: ComponentActionListener.h:1018
PreComponentActionListenerHolder()
Constructor.
@ PRE_ON_ERROR
Definition: ComponentActionListener.h:66
@ PRE_ON_FINALIZE
Definition: ComponentActionListener.h:60
PostComponentActionListenerHolder postaction_[POST_COMPONENT_ACTION_LISTENER_NUM]
PostComponentActionType listener array The PostComponentActionType listener is stored.
Definition: ComponentActionListener.h:1042
@ PRE_ON_EXECUTE
Definition: ComponentActionListener.h:68
PreComponentActionListenerHolder preaction_[PRE_COMPONENT_ACTION_LISTENER_NUM]
PreComponentActionListenerType listener array The PreComponentActionListenerType listener is stored.
Definition: ComponentActionListener.h:1031
virtual ~PortActionListenerHolder()
Destructor.
@ PRE_ON_DEACTIVATED
Definition: ComponentActionListener.h:64
void removeListener(PreComponentActionListener *listener)
Remove the listener.
@ POST_ON_STARTUP
Definition: ComponentActionListener.h:223
PreComponentActionListener holder class.
Definition: ComponentActionListener.h:594
ExecutionContextHandle_t UniqueId
Definition: ComponentActionListener.h:32
void addListener(PortActionListener *listener, bool autoclean)
Add the listener.
PostComponentActionListenerType
The types of ConnectorDataListener.
Definition: ComponentActionListener.h:219
virtual void operator()(UniqueId ec_id)=0
Virtual Callback function.
@ POST_ON_DEACTIVATED
Definition: ComponentActionListener.h:226
PortActionListenerType
The types of PortActionListener.
Definition: ComponentActionListener.h:376
void removeListener(PortActionListener *listener)
Remove the listener.
static const char * toString(PostComponentActionListenerType type)
Convert PostComponentActionListenerType into the string.
Definition: ComponentActionListener.h:309
@ POST_ON_ERROR
Definition: ComponentActionListener.h:228
@ PRE_ON_ACTIVATED
Definition: ComponentActionListener.h:63
PostComponentActionListener class.
Definition: ComponentActionListener.h:283
PortActionListenerHolder()
Constructor.
virtual ~ExecutionContextActionListener()
Destructor.
@ PRE_ON_ABORTING
Definition: ComponentActionListener.h:65
virtual ~PreComponentActionListenerHolder()
Destructor.
@ REMOVE_PORT
Definition: ComponentActionListener.h:379
ExecutionContextActionListener holder class.
Definition: ComponentActionListener.h:914
ExecutionContextActionListenerType
The types of ExecutionContextActionListener.
Definition: ComponentActionListener.h:483
void removeListener(ExecutionContextActionListener *listener)
Remove the listener.