#include <RtcBase.h>
Public Member Functions | |
RtcBase () | |
A constructor of RtcBase class. | |
RtcBase (CORBA::ORB_ptr orb, PortableServer::POA_ptr poa) | |
A constructor of RtcBase class. | |
RtcBase (RtcManager *manager) | |
A constructor. | |
virtual | ~RtcBase () |
A destructor of RtcBase class. | |
virtual RtmRes | rtc_start () throw (CORBA::SystemException, RTM::RTComponent::IllegalTransition) |
[CORBA interface] Activate this components' activity | |
virtual RtmRes | rtc_stop () throw (CORBA::SystemException, RTM::RTComponent::IllegalTransition) |
[CORBA interface] Stop this component's activity | |
virtual RtmRes | rtc_reset () throw (CORBA::SystemException, RTM::RTComponent::IllegalTransition) |
[CORBA interface] Go to init() state from error() state | |
virtual RtmRes | rtc_exit () throw (CORBA::SystemException, RTM::RTComponent::IllegalTransition) |
[CORBA interface] Go to term() state from anywhere | |
virtual RtmRes | rtc_kill () |
[CORBA interface] Go to exiting() state from active() state | |
virtual RtmRes | rtc_worker () |
[CORBA interface] Main activity function. | |
virtual RtmRes | rtc_ready_entry () |
[CORBA interface] entry: ready() method. | |
virtual RtmRes | rtc_ready_do () |
[CORBA interface] do: ready() method. | |
virtual RtmRes | rtc_ready_exit () |
[CORBA interface] exit: ready() method. | |
virtual RtmRes | rtc_active_entry () |
[CORBA interface] entry: active() method. | |
virtual RtmRes | rtc_active_do () |
[CORBA interface] do: active() method. | |
virtual RtmRes | rtc_active_exit () |
[CORBA interface] exit: active() method. | |
virtual RtmRes | rtc_error_entry () |
[CORBA interface] entry: error() method. | |
virtual RtmRes | rtc_error_do () |
[CORBA interface] do: ready() method. | |
virtual RtmRes | rtc_error_exit () |
[CORBA interface] exit: error() method. | |
virtual RtmRes | rtc_fatal_entry () |
[CORBA interface] entry: fatal() method. | |
virtual RtmRes | rtc_fatal_do () |
[CORBA interface] do: fatal() method. | |
virtual RtmRes | rtc_fatal_exit () |
[CORBA interface] exit: fatal() method. | |
virtual RtmRes | rtc_init_entry () |
[CORBA interface] entry: ready() method. | |
virtual RtmRes | rtc_starting_entry () |
[CORBA interface] entry: starting() method. | |
virtual RtmRes | rtc_stopping_entry () |
[CORBA interface] entry: stopping() method. | |
virtual RtmRes | rtc_aborting_entry () |
[CORBA interface] entry: aborting() method. | |
virtual RtmRes | rtc_exiting_entry () |
[CORBA interface] entry: exiting() method. | |
virtual OutPort_ptr | rtc_state () |
[CORBA interface] Get activity status OutPort | |
virtual InPortList * | inports () |
[CORBA interface] Return input port object reference list | |
virtual InPort_ptr | get_inport (const char *name) throw (CORBA::SystemException, RTM::RTComponent::NoSuchName) |
[CORBA interface] Return input port object reference | |
virtual OutPortList * | outports () |
[CORBA interface] Return output port object reference list | |
virtual OutPort_ptr | get_outport (const char *name) throw (CORBA::SystemException, RTM::RTComponent::NoSuchName) |
[CORBA interface] Return output port object reference | |
virtual char * | instance_id () |
[CORBA interface] get instance_id | |
virtual char * | implementation_id () |
[CORBA interface] get implementation_id | |
virtual char * | description () |
[CORBA interface] get description | |
virtual char * | version () |
[CORBA interface] get version | |
virtual char * | maker () |
[CORBA interface] get maker | |
virtual char * | category () |
[CORBA interface] get category | |
virtual RTCProfile * | profile () |
[CORBA interface] get profile | |
virtual RtmRes | rtc_start_thread () |
[CORBA interface] Start activity internal thread | |
virtual RtmRes | rtc_suspend_thread () |
[CORBA interface] Suspend activity internal thread | |
virtual RtmRes | rtc_stop_thread () |
[CORBA interface] Stop activity internal thread | |
virtual RtmRes | rtc_set_parent (RTCBase_ptr comp) |
[CORBA interface] Set parent component | |
virtual RtmRes | rtc_add_component (RTCBase_ptr comp) |
[CORBA interface] Set child component | |
virtual RtmRes | rtc_delete_component (RTCBase_ptr comp) |
[CORBA interface] Delete child component | |
virtual RtmRes | rtc_replace_component (RTCBase_ptr comp1, RTCBase_ptr comp2) |
[CORBA interface] Replace two child components | |
virtual RtmRes | rtc_replace_component_by_name (const char *name1, const char *name2) |
[CORBA interface] Replace two child components | |
virtual RTCBaseList * | rtc_components () |
[CORBA interface] Get child components list | |
virtual RTCBase_ptr | rtc_get_component (const char *name) |
[CORBA interface] Get child components list | |
virtual RtmRes | rtc_attach_inport (InPort_ptr in_port) |
[CORBA interface] Get child components list | |
virtual RtmRes | rtc_attach_inport_by_name (RTCBase_ptr comp, const char *name) |
[CORBA interface] Get child components list | |
virtual RtmRes | rtc_detatch_inport (InPort_ptr in_port) |
[CORBA interface] Get child components list | |
virtual RtmRes | rtc_detatch_inport_by_name (const char *name) |
[CORBA interface] Get child components list | |
virtual RtmRes | rtc_attach_outport (OutPort_ptr out_port) |
[CORBA interface] Get child components list | |
virtual RtmRes | rtc_attach_outport_by_name (RTCBase_ptr comp, const char *name) |
[CORBA interface] Get child components list | |
virtual RtmRes | rtc_detatch_outport (OutPort_ptr out_port) |
[CORBA interface] Get child components list | |
virtual RtmRes | rtc_detatch_outport_by_name (const char *name) |
[CORBA interface] Get child components list | |
virtual void | init_orb (CORBA::ORB_ptr orb, PortableServer::POA_ptr poa) |
Initialize this component with ORB and POA pointer. | |
virtual int | open (void *args) |
Create internal activity thread. | |
virtual int | svc (void) |
Create internal activity thread. | |
virtual int | close (unsigned long flags) |
Close activity thread. | |
virtual RTM::RTComponent::ComponentState | getState () |
Get current component state. | |
virtual void | initModuleProfile (RtcModuleProfile prof) |
Initialize RtcModuleProfile. | |
virtual RtcModuleProfile & | getModuleProfile () |
Get RtcModuleProfile. | |
virtual string | setComponentName (int num) |
Set component name. | |
bool | registerInPort (InPortBase &in_ch) |
Registration of input channel. | |
bool | registerPort (InPortBase &in_ch) |
Registration of input channel. | |
bool | deleteInPort (InPortBase &in_ch) |
Deletion of InPort. | |
bool | deletePort (InPortBase &in_ch) |
Deletion of InPort. | |
bool | deleteInPortByName (const char *ch_name) |
Deletion of input channel by channel name. | |
void | readAllInPorts () |
Read all data to InPorts and bound variable. | |
void | finalizeInPorts () |
Finalize all InPorts. | |
bool | registerOutPort (OutPortBase &out_ch) |
Registration of output channel. | |
bool | registerPort (OutPortBase &out_ch) |
bool | deleteOutPort (OutPortBase &out_ch) |
Deletion of output channel. | |
bool | deletePort (OutPortBase &out_ch) |
Deletion of output channel. | |
bool | deleteOutPortByName (const char *ch_name) |
Deletion of output channel by channel name. | |
void | writeAllOutPorts () |
Write all data to OutPorts from bound variables. | |
void | finalizeOutPorts () |
Finalize all OutPorts. | |
void | appendAlias (const char *alias) |
Register alias of component name. | |
void | appendAlias (const std::string alias) |
Register alias of component name. | |
std::list< string > | getAliases () |
Get registered aliases of component name. | |
void | setNamingPolicy (NamingPolicy policy) |
NamingPolicy | getNamingPolicy () |
bool | isLongNameEnable () |
bool | isAliasEnable () |
void | forceExit () |
void | finalize () |
Get registered aliases of component name. | |
bool | isThreadRunning () |
Protected Types | |
typedef RtmRes(RtcBase::* | StateFunc )() |
activity function pointer definition | |
typedef list< InPortBase * >::iterator | InPorts_it |
InPort list iterator. | |
typedef list< OutPortBase * >::iterator | OutPorts_it |
OutPort list iterator. | |
enum | ThreadStates { UNKNOWN, RUNNING, SUSPEND, STOP } |
activity thread state structure More... | |
Protected Member Functions | |
RtmRes | _check_error (RtmRes result) |
activity error check function | |
RtmRes | _nop () |
dummy function for activity | |
RtmRes | _rtc_initializing () |
rtc_init_entry execution function for activity | |
RtmRes | _rtc_ready_entry () |
rtc_ready_entry execution function for activity | |
RtmRes | _rtc_starting () |
rtc_starting_entry execution function for activity | |
RtmRes | _rtc_active_entry () |
rtc_active_entry execution function for activity | |
RtmRes | _rtc_stopping () |
rtc_stopping_entry execution function for activity | |
RtmRes | _rtc_aborting () |
rtc_aborting_entry execution function for activity | |
RtmRes | _rtc_error_entry () |
rtc_error_entry execution function for activity | |
RtmRes | _rtc_fatal_entry () |
rtc_fatal_entry execution function for activity | |
RtmRes | _rtc_exiting () |
rtc_exiting_entry execution function for activity | |
RtmRes | _rtc_ready () |
rtc_ready_do execution function for activity | |
RtmRes | _rtc_active () |
rtc_active_do execution function for activity | |
RtmRes | _rtc_error () |
rtc_error_do execution function for activity | |
RtmRes | _rtc_fatal () |
rtc_fatal_do execution function for activity | |
RtmRes | _rtc_ready_exit () |
rtc_ready_exit execution function for activity | |
RtmRes | _rtc_active_exit () |
rtc_active_exit execution function for activity | |
RtmRes | _rtc_error_exit () |
rtc_error_exit execution function for activity | |
RtmRes | _rtc_fatal_exit () |
rtc_fatal_exit execution function for activity | |
void | init_state_func_table () |
initialize activity function table | |
Protected Attributes | |
CORBA::ORB_ptr | m_pORB |
pointer to ORB | |
PortableServer::POA_ptr | m_pPOA |
pointer to POA | |
RtcManager * | m_pManager |
pointer to Manager | |
RTCBase_var | m_Parent |
object reference to parent component | |
ThreadState | m_ThreadState |
activity thread state variable | |
ComponentStateMtx | m_CurrentState |
activity current state varible | |
ComponentStateMtx | m_NextState |
activity next state varible | |
StateFunc | _exit_func [11] |
exit function table of activity | |
StateFunc | _entry_func [11] |
entry function table of activity | |
StateFunc | _do_func [11] |
do function table of activity | |
InPorts | m_InPorts |
InPort list with mutex. | |
OutPorts | m_OutPorts |
OutPort list with mutex. | |
TimedState | m_TimedState |
Input port flag list activity state variable. | |
OutPortAny< TimedState > | m_StatePort |
activity state OutPort | |
RtcModuleProfile | m_Profile |
component profile | |
std::list< string > | m_Alias |
Aliases of component name. | |
NamingPolicy | m_NamingPolicy |
RtcMedLogbuf | m_MedLogbuf |
Logger mediation buffer. | |
RtcLogStream | rtcout |
Logger stream. |
RT-component developer should derive this base class to create own RT component class. Procedure is as follows.
In your RT-conponent class, you have to define input variable and output variable. Input channel and output channel also should be defined as InPort<T> objects or OutPort<T> objects. These variables and channel objects should be bound each other in the constructor.
In the constructor of your component class, input channel objects and output channel objects have to make registration as CORBA objects using registerInPort , registerOutPort method.
|
InPort list iterator.
|
|
OutPort list iterator.
|
|
activity function pointer definition
|
|
activity thread state structure
|
|
A constructor of RtcBase class. Constructor of RtcBase which is RTComponent servant implementation base classes without arguments. If use this constructor, user have to set the ORB pointer and a POA pointer or a pointer to RtcManager. |
|
A constructor of RtcBase class. If the ORB pointer and a POA pointer are already available, user can use this constructor.
|
|
A constructor.
|
|
A destructor of RtcBase class.
|
|
activity error check function
|
|
dummy function for activity
|
|
rtc_aborting_entry execution function for activity
|
|
rtc_active_do execution function for activity
|
|
rtc_active_entry execution function for activity
|
|
rtc_active_exit execution function for activity
|
|
rtc_error_do execution function for activity
|
|
rtc_error_entry execution function for activity
|
|
rtc_error_exit execution function for activity
|
|
rtc_exiting_entry execution function for activity
|
|
rtc_fatal_do execution function for activity
|
|
rtc_fatal_entry execution function for activity
|
|
rtc_fatal_exit execution function for activity
|
|
rtc_init_entry execution function for activity
|
|
rtc_ready_do execution function for activity
|
|
rtc_ready_entry execution function for activity
|
|
rtc_ready_exit execution function for activity
|
|
rtc_starting_entry execution function for activity
|
|
rtc_stopping_entry execution function for activity
|
|
Register alias of component name. This method register alias of component name. Registered alias will bind to naming server. Context delimiter is "/", id/kind delimiter is "|". If you want to bind your component "MyManipulator0" under a context "Manipulator", you should give an char* argument like "/Manipulator/MyManipulator|rtc". This component will be bound to naming server on this alias.
|
|
Register alias of component name. This method register alias of component name. Registered alias will bind to naming server. Context delimiter is "/", id/kind delimiter is "|". If you want to bind your component "MyManipulator0" under a context "Manipulator", you should give an char* argument like "/Manipulator/MyManipulator|rtc". This component will be bound to naming server on this alias.
|
|
[CORBA interface] get category
|
|
Close activity thread. close() method is called when activity thread svc() is returned. This method deactivate this object and notify it to manager. ACE_Task class method override. |
|
Deletion of InPort. "false" is returned when the object of the argument is not registered.
|
|
Deletion of input channel by channel name. "false" is returned when the object of the argument is not registered.
|
|
Deletion of output channel. "false" is returned when the object of the argument is not registered.
|
|
Deletion of output channel by channel name. "false" is returned when the object of the argument is not registered.
|
|
Deletion of output channel. "false" is returned when the object of the argument is not registered.
|
|
Deletion of InPort. "false" is returned when the object of the argument is not registered.
|
|
[CORBA interface] get description
|
|
Get registered aliases of component name.
|
|
Finalize all InPorts. Finalize all registered InPorts and deactivate as a CORBA objects. |
|
Finalize all OutPorts. Finalize all registered OutPorts and deactivate as a CORBA objects. |
|
|
|
[CORBA interface] Return input port object reference
|
|
[CORBA interface] Return output port object reference
|
|
Get registered aliases of component name.
|
|
Get RtcModuleProfile. Get RtcModuleProfile |
|
|
|
Get current component state.
|
|
[CORBA interface] get implementation_id
|
|
Initialize this component with ORB and POA pointer.
|
|
initialize activity function table
|
|
Initialize RtcModuleProfile.
|
|
[CORBA interface] Return input port object reference list
|
|
[CORBA interface] get instance_id
|
|
|
|
|
|
|
|
[CORBA interface] get maker
|
|
Create internal activity thread. Create internal activity thread. This is ACE_Task class method over ride.
|
|
[CORBA interface] Return output port object reference list
|
|
[CORBA interface] get profile
|
|
Read all data to InPorts and bound variable. Invoke InPort::read() to all registered InPorts. |
|
Registration of input channel. Duplication of a name of input channel is not allowed. "false" will be returned when there is duplication of a name.
|
|
Registration of output channel. Duplication of a name of output channel is not allowed. "false" will be returned when there is duplication of a name.
|
|
|
|
Registration of input channel. Duplication of a name of input channel is not allowed. "false" will be returned when there is duplication of a name.
|
|
[CORBA interface] entry: aborting() method. This method will be called and move to Error state immediately. |
|
[CORBA interface] do: active() method. This method will be called repeatedly when component state is Active. |
|
[CORBA interface] entry: active() method. This method will be called once when component enter to Active state. |
|
[CORBA interface] exit: active() method. This method will be called once when component exit from Active state. |
|
[CORBA interface] Set child component
|
|
[CORBA interface] Get child components list
|
|
[CORBA interface] Get child components list
|
|
[CORBA interface] Get child components list
|
|
[CORBA interface] Get child components list
|
|
[CORBA interface] Get child components list
|
|
[CORBA interface] Delete child component
|
|
[CORBA interface] Get child components list
|
|
[CORBA interface] Get child components list
|
|
[CORBA interface] Get child components list
|
|
[CORBA interface] Get child components list
|
|
[CORBA interface] do: ready() method. This method will be called repeatedly when component state is Error. |
|
[CORBA interface] entry: error() method. This method will be called once when component enter to Error state. |
|
[CORBA interface] exit: error() method. This method will be called once when component exit from Error state. |
|
[CORBA interface] Go to term() state from anywhere
|
|
[CORBA interface] entry: exiting() method. This method will be called and terminate component. |
|
[CORBA interface] do: fatal() method. This method will be called repeatedly when component state is FATAL_ERROR state. |
|
[CORBA interface] entry: fatal() method. This method will be called once when component enter to FATAL_ERROR state. |
|
[CORBA interface] exit: fatal() method. This method will be called once when component exit from FATAL_ERROR state. |
|
[CORBA interface] Get child components list
|
|
[CORBA interface] entry: ready() method. This method will be called and move to Ready/Error state immediately. |
|
[CORBA interface] Go to exiting() state from active() state
|
|
[CORBA interface] do: ready() method. This method will be called repeatedly when component state is Ready. |
|
[CORBA interface] entry: ready() method. This method will be called once when component enter to Ready state. |
|
[CORBA interface] exit: ready() method. This method will be called once when component exit from Ready state. |
|
[CORBA interface] Replace two child components
|
|
[CORBA interface] Replace two child components
|
|
[CORBA interface] Go to init() state from error() state
|
|
[CORBA interface] Set parent component
|
|
[CORBA interface] Activate this components' activity
|
|
[CORBA interface] Start activity internal thread
|
|
[CORBA interface] entry: starting() method. This method will be called and move to Active state immediately. |
|
[CORBA interface] Get activity status OutPort
|
|
[CORBA interface] Stop this component's activity
|
|
[CORBA interface] Stop activity internal thread
|
|
[CORBA interface] entry: stopping() method. This method will be called and move to Ready state immediately. |
|
[CORBA interface] Suspend activity internal thread
|
|
[CORBA interface] Main activity function. Called from activity thread periodically. |
|
Set component name.
|
|
|
|
Create internal activity thread. Run by a daemon thread to handle deferred processing. ACE_Task class method override. |
|
[CORBA interface] get version
|
|
Write all data to OutPorts from bound variables. Invoke OutPort::write() to all registered OutPorts. |
|
do function table of activity
|
|
entry function table of activity
|
|
exit function table of activity
|
|
Aliases of component name.
|
|
activity current state varible
|
|
InPort list with mutex.
|
|
Logger mediation buffer.
|
|
|
|
activity next state varible
|
|
OutPort list with mutex.
|
|
object reference to parent component
|
|
pointer to Manager
|
|
pointer to ORB
|
|
pointer to POA
|
|
component profile
|
|
activity state OutPort
|
|
activity thread state variable
|
|
Input port flag list activity state variable.
|
|
Logger stream.
|