Public Member Functions | Private Member Functions | Private Attributes | List of all members
RTC::OutPortCorbaCdrConsumer Class Reference

OutPortCorbaCdrConsumer class. More...

#include <OutPortCorbaCdrConsumer.h>

Inheritance diagram for RTC::OutPortCorbaCdrConsumer:
Inheritance graph
[legend]

Public Member Functions

virtual ReturnCode get (cdrMemoryStream &data)
 Read data. More...
 
virtual void init (coil::Properties &prop)
 Initializing configuration. More...
 
DATAPORTSTATUS_ENUM OutPortCorbaCdrConsumer ()
 Constructor. More...
 
virtual void setBuffer (CdrBufferBase *buffer)
 Setting outside buffer's pointer. More...
 
virtual void setListener (ConnectorInfo &info, ConnectorListeners *listeners)
 Set the listener. More...
 
virtual bool subscribeInterface (const SDOPackage::NVList &properties)
 Subscribe the data receive notification. More...
 
virtual void unsubscribeInterface (const SDOPackage::NVList &properties)
 Unsubscribe the data receive notification. More...
 
virtual ~OutPortCorbaCdrConsumer (void)
 Destructor. More...
 
- Public Member Functions inherited from RTC::OutPortConsumer
virtual DATAPORTSTATUS_ENUM ~OutPortConsumer (void)
 Destructor. More...
 
- Public Member Functions inherited from RTC::CorbaConsumer< ::OpenRTM::OutPortCdr >
typename ::OpenRTM::OutPortCdr ::_ptr_type _ptr ()
 Get Object reference narrowed as ObjectType. More...
 
 CorbaConsumer ()
 Consructor. More...
 
 CorbaConsumer (const CorbaConsumer &x)
 Copy constructor. More...
 
typename ::OpenRTM::OutPortCdr ::_ptr_type operator-> ()
 Get Object reference narrowed as ObjectType. More...
 
CorbaConsumeroperator= (const CorbaConsumer &x)
 Assignment operator. More...
 
virtual void releaseObject ()
 Clear CORBA object setting. More...
 
virtual bool setObject (CORBA::Object_ptr obj)
 Set Object. More...
 
void swap (CorbaConsumer &x)
 
virtual ~CorbaConsumer (void)
 Virtual destructor. More...
 
- Public Member Functions inherited from RTC::CorbaConsumerBase
 CorbaConsumerBase ()
 Consructor. More...
 
 CorbaConsumerBase (const CorbaConsumerBase &x)
 Copy Consructor. More...
 
virtual CORBA::Object_ptr getObject ()
 Get CORBA Object. More...
 
CorbaConsumerBaseoperator= (const CorbaConsumerBase &x)
 Assignment operator. More...
 
void swap (CorbaConsumerBase &x)
 swap function More...
 
virtual ~CorbaConsumerBase (void)
 Virtual destructor. More...
 

Private Member Functions

OutPortConsumer::ReturnCode convertReturn (::OpenRTM::PortStatus status, const cdrMemoryStream &data)
 Return codes conversion. More...
 
void onBufferFull (const cdrMemoryStream &data)
 Notify an ON_BUFFER_FULL event to listeners. More...
 
void onBufferWrite (const cdrMemoryStream &data)
 Notify an ON_BUFFER_WRITE event to listeners. More...
 
void onReceived (const cdrMemoryStream &data)
 Notify an ON_RECEIVED event to listeners. More...
 
void onReceiverFull (const cdrMemoryStream &data)
 Notify an ON_RECEIVER_FULL event to listeners. More...
 
void onSenderEmpty ()
 Notify an ON_SENDER_EMPTY event to listeners. More...
 
void onSenderError ()
 
void onSenderTimeout ()
 Notify an ON_SENDER_TIMEOUT event to listeners. More...
 

Private Attributes

CdrBufferBasem_buffer
 
ConnectorListenersm_listeners
 
ConnectorInfo m_profile
 

Additional Inherited Members

- Public Types inherited from RTC::DataPortStatus
enum  Enum {
  PORT_OK = 0, PORT_ERROR, BUFFER_ERROR, BUFFER_FULL,
  BUFFER_EMPTY, BUFFER_TIMEOUT, SEND_FULL, SEND_TIMEOUT,
  RECV_EMPTY, RECV_TIMEOUT, INVALID_ARGS, PRECONDITION_NOT_MET,
  CONNECTION_LOST, UNKNOWN_ERROR
}
 DataPortStatus return codes. More...
 
- Static Public Member Functions inherited from RTC::DataPortStatus
static const char * toString (DataPortStatus::Enum status)
 Convert DataPortStatus into the string. More...
 
- Protected Attributes inherited from RTC::OutPortConsumer
Logger rtclog
 Logger stream. More...
 
- Protected Attributes inherited from RTC::CorbaConsumer< ::OpenRTM::OutPortCdr >
typename ::OpenRTM::OutPortCdr ::_var_type m_var
 CORBA object which has been set. More...
 
- Protected Attributes inherited from RTC::CorbaConsumerBase
CORBA::Object_var m_objref
 CORBA object which is set. More...
 

Detailed Description

OutPortCorbaCdrConsumer class.

The OutPort consumer class which uses the OpenRTM::OutPortCdr interface in CORBA for data transfer and realizes a pull-type dataflow.

Since
0.4.0

Definition at line 55 of file OutPortCorbaCdrConsumer.h.

Constructor & Destructor Documentation

◆ OutPortCorbaCdrConsumer()

RTC::OutPortCorbaCdrConsumer::OutPortCorbaCdrConsumer ( )

Constructor.

Constructor

Definition at line 33 of file OutPortCorbaCdrConsumer.cpp.

◆ ~OutPortCorbaCdrConsumer()

RTC::OutPortCorbaCdrConsumer::~OutPortCorbaCdrConsumer ( void  )
virtual

Destructor.

Destructor

Definition at line 45 of file OutPortCorbaCdrConsumer.cpp.

Member Function Documentation

◆ convertReturn()

OutPortConsumer::ReturnCode RTC::OutPortCorbaCdrConsumer::convertReturn ( ::OpenRTM::PortStatus  status,
const cdrMemoryStream &  data 
)
private

Return codes conversion.

Definition at line 226 of file OutPortCorbaCdrConsumer.cpp.

◆ get()

OutPortConsumer::ReturnCode RTC::OutPortCorbaCdrConsumer::get ( cdrMemoryStream &  data)
virtual

Read data.

Read set data

Parameters
dataObject to receive the read data
Returns
Read result (Successful:true, Failed:false)

Implements RTC::OutPortConsumer.

Definition at line 97 of file OutPortCorbaCdrConsumer.cpp.

◆ init()

void RTC::OutPortCorbaCdrConsumer::init ( coil::Properties prop)
virtual

Initializing configuration.

This operation would be called to configure in initialization. In the concrete class, configuration should be performed getting appropriate information from the given Properties data. This function might be called right after instantiation and connection sequence respectivly. Therefore, this function should be implemented assuming multiple call.

Parameters
propConfiguration information

Implements RTC::OutPortConsumer.

Definition at line 56 of file OutPortCorbaCdrConsumer.cpp.

◆ onBufferFull()

void RTC::OutPortCorbaCdrConsumer::onBufferFull ( const cdrMemoryStream &  data)
inlineprivate

Notify an ON_BUFFER_FULL event to listeners.

Parameters
datacdrMemoryStream

Definition at line 296 of file OutPortCorbaCdrConsumer.h.

◆ onBufferWrite()

void RTC::OutPortCorbaCdrConsumer::onBufferWrite ( const cdrMemoryStream &  data)
inlineprivate

Notify an ON_BUFFER_WRITE event to listeners.

Parameters
datacdrMemoryStream

Definition at line 281 of file OutPortCorbaCdrConsumer.h.

◆ onReceived()

void RTC::OutPortCorbaCdrConsumer::onReceived ( const cdrMemoryStream &  data)
inlineprivate

Notify an ON_RECEIVED event to listeners.

Parameters
datacdrMemoryStream

Definition at line 311 of file OutPortCorbaCdrConsumer.h.

◆ onReceiverFull()

void RTC::OutPortCorbaCdrConsumer::onReceiverFull ( const cdrMemoryStream &  data)
inlineprivate

Notify an ON_RECEIVER_FULL event to listeners.

Parameters
datacdrMemoryStream

Definition at line 326 of file OutPortCorbaCdrConsumer.h.

◆ onSenderEmpty()

void RTC::OutPortCorbaCdrConsumer::onSenderEmpty ( )
inlineprivate

Notify an ON_SENDER_EMPTY event to listeners.

Definition at line 339 of file OutPortCorbaCdrConsumer.h.

◆ onSenderError()

void RTC::OutPortCorbaCdrConsumer::onSenderError ( )
inlineprivate

Notify an ON_SENDER_ERROR event to listeners

Definition at line 365 of file OutPortCorbaCdrConsumer.h.

◆ onSenderTimeout()

void RTC::OutPortCorbaCdrConsumer::onSenderTimeout ( )
inlineprivate

Notify an ON_SENDER_TIMEOUT event to listeners.

Definition at line 352 of file OutPortCorbaCdrConsumer.h.

◆ setBuffer()

void RTC::OutPortCorbaCdrConsumer::setBuffer ( CdrBufferBase buffer)
virtual

Setting outside buffer's pointer.

A pointer to a buffer from which OutPortProvider retrieve data. If already buffer is set, previous buffer's pointer will be overwritten by the given pointer to a buffer. Since OutPortProvider does not assume ownership of the buffer pointer, destructor of the buffer should be done by user.

Parameters
bufferA pointer to a data buffer to be used by OutPortProvider

Implements RTC::OutPortConsumer.

Definition at line 68 of file OutPortCorbaCdrConsumer.cpp.

◆ setListener()

void RTC::OutPortCorbaCdrConsumer::setListener ( ConnectorInfo info,
ConnectorListeners listeners 
)
virtual

Set the listener.

OutPort provides callback functionality that calls specific listener objects according to the events in the data publishing process. For details, see documentation of ConnectorDataListener class and ConnectorListener class in ConnectorListener.h. In this OutPortCorbaCdrProvider provides the following callbacks.

  • ON_BUFFER_WRITE
  • ON_BUFFER_FULL
  • ON_RECEIVED
  • ON_RECEIVER_FULL
  • ON_SENDER_EMPTY
  • ON_SENDER_TIMEOUT
  • ON_SENDER_ERROR
Parameters
infoConnector information
listenersListener objects

Implements RTC::OutPortConsumer.

Definition at line 81 of file OutPortCorbaCdrConsumer.cpp.

◆ subscribeInterface()

bool RTC::OutPortCorbaCdrConsumer::subscribeInterface ( const SDOPackage::NVList &  properties)
virtual

Subscribe the data receive notification.

Subscribe the data receive notification based on specified property information

Parameters
propertiesSubscription information
Returns
Subscription result (Successful:true, Failed:false)

Implements RTC::OutPortConsumer.

Definition at line 146 of file OutPortCorbaCdrConsumer.cpp.

◆ unsubscribeInterface()

void RTC::OutPortCorbaCdrConsumer::unsubscribeInterface ( const SDOPackage::NVList &  properties)
virtual

Unsubscribe the data receive notification.

Unsubscribe the data receive notification.

Parameters
propertiesUnsubscription information

Implements RTC::OutPortConsumer.

Definition at line 190 of file OutPortCorbaCdrConsumer.cpp.

Member Data Documentation

◆ m_buffer

CdrBufferBase* RTC::OutPortCorbaCdrConsumer::m_buffer
private

Definition at line 372 of file OutPortCorbaCdrConsumer.h.

◆ m_listeners

ConnectorListeners* RTC::OutPortCorbaCdrConsumer::m_listeners
private

Definition at line 373 of file OutPortCorbaCdrConsumer.h.

◆ m_profile

ConnectorInfo RTC::OutPortCorbaCdrConsumer::m_profile
private

Definition at line 374 of file OutPortCorbaCdrConsumer.h.


The documentation for this class was generated from the following files:


openrtm_aist
Author(s): Noriaki Ando
autogenerated on Mon Feb 28 2022 23:00:47