#include <OutPort.h>
Public Member Functions | |
OutPort (const char *name, DataType &value) | |
Constructor. | |
virtual | ~OutPort (void) |
Destructor. | |
virtual bool | write (DataType &value) |
Write data. | |
bool | write () |
Write data. | |
bool | operator<< (DataType &value) |
Write data. | |
bool | read (DataType &value) |
Readout the data. | |
void | setReadBlock (bool block) |
Set blocking mode of the data read processing. | |
void | setWriteBlock (bool block) |
Set blocking mode of the data writing processing. | |
void | setReadTimeout (long int timeout) |
Set timeout of the data read processing. | |
void | setWriteTimeout (long int timeout) |
Set timeout of the data writing processing. | |
void | setOnWrite (OnWrite< DataType > *on_write) |
Set OnWrite callback. | |
void | setOnWriteConvert (OnWriteConvert< DataType > *on_wconvert) |
Set OnWriteConvert callback. | |
void | setOnOverflow (OnOverflow< DataType > *on_overflow) |
Set OnOverflow callback. | |
void | setOnRead (OnRead< DataType > *on_read) |
Set OnRead callback. | |
void | setOnReadConvert (OnReadConvert< DataType > *on_rconvert) |
Set OnReadConvert callback. | |
void | setOnUnderflow (OnUnderflow< DataType > *on_underflow) |
Set OnUnderflow callback. | |
void | setOnConnect (OnConnect *on_connect) |
void | setOnDisconnect (OnConnect *on_disconnect) |
virtual void | onConnect (const char *id, PublisherBase *publisher) |
Publish interface information. | |
virtual void | onDisconnect (const char *id) |
Classes | |
struct | subscribe |
This is the OutPort template class. The data type "DateType" supported by OutPort and the buffer type "BufferType" are used as template arguments.
RTC::OutPort< DataType >::OutPort | ( | const char * | name, | |
DataType & | value | |||
) | [inline] |
Constructor.
Constructor
name | Port's name | |
value | Data variable bound to this port | |
length | Buffer length (The default value:8) |
virtual RTC::OutPort< DataType >::~OutPort | ( | void | ) | [inline, virtual] |
Destructor.
Destructor
virtual bool RTC::OutPort< DataType >::write | ( | DataType & | value | ) | [inline, virtual] |
Write data.
Write data in the port.
value | The target data for writing |
bool RTC::OutPort< DataType >::write | ( | ) | [inline] |
Write data.
Write data to the port. Write the value, which was set to the bound variable, to the port.
bool RTC::OutPort< DataType >::operator<< | ( | DataType & | value | ) | [inline] |
Write data.
Write data to the port. Write the set value to the port.
value | The target data for writing |
bool RTC::OutPort< DataType >::read | ( | DataType & | value | ) | [inline] |
Readout the data.
Readout the value from DataPort
value | Readout data |
void RTC::OutPort< DataType >::setReadBlock | ( | bool | block | ) | [inline] |
Set blocking mode of the data read processing.
Set the blocking mode for the readout. When the block mode is specified, the invoke of read() method is blocked until the readout data is received or timeout occurs.
block | Flag of blocking mode |
void RTC::OutPort< DataType >::setWriteBlock | ( | bool | block | ) | [inline] |
Set blocking mode of the data writing processing.
Set the blocking mode for the writing. When the block mode is specified, the invoke of write() method is blocked until the area written into the buffer can be used or timeout occurs.
block | Flag of blocking mode |
void RTC::OutPort< DataType >::setReadTimeout | ( | long int | timeout | ) | [inline] |
void RTC::OutPort< DataType >::setWriteTimeout | ( | long int | timeout | ) | [inline] |
void RTC::OutPort< DataType >::setOnWrite | ( | OnWrite< DataType > * | on_write | ) | [inline] |
void RTC::OutPort< DataType >::setOnWriteConvert | ( | OnWriteConvert< DataType > * | on_wconvert | ) | [inline] |
Set OnWriteConvert callback.
Set OnWriteConvert callback functor invoked when data is written. The processing result of this callback function is written. Therefore, filtering of the writing data will be possible.
on_wconvert | OnWriteConvert callback functor |
void RTC::OutPort< DataType >::setOnOverflow | ( | OnOverflow< DataType > * | on_overflow | ) | [inline] |
Set OnOverflow callback.
Set OnOverflow callback functor, which is invoked when data cannot be written because of the buffer full.
on_overflow | OnOverflow callback functor |
void RTC::OutPort< DataType >::setOnRead | ( | OnRead< DataType > * | on_read | ) | [inline] |
void RTC::OutPort< DataType >::setOnReadConvert | ( | OnReadConvert< DataType > * | on_rconvert | ) | [inline] |
Set OnReadConvert callback.
Set OnReadConvert callback functor invoked when data is readout. The processing result of this callback function is readout. Therefore, filtering of the read data will be possible.
on_rconvert | OnReadConvert callback functor |
void RTC::OutPort< DataType >::setOnUnderflow | ( | OnUnderflow< DataType > * | on_underflow | ) | [inline] |
Set OnUnderflow callback.
Set OnUnderflow callback functor, which is invoked when data cannot be readout because of the buffer empty.
on_underflow | OnUnderflow callback functor |
void RTC::OutPort< DataType >::setOnConnect | ( | OnConnect * | on_connect | ) | [inline] |
void RTC::OutPort< DataType >::setOnDisconnect | ( | OnConnect * | on_disconnect | ) | [inline] |
virtual void RTC::OutPort< DataType >::onConnect | ( | const char * | id, | |
PublisherBase * | publisher | |||
) | [inline, virtual] |
Publish interface information.
Publish interface information.
connector_profile | The connector profile in which interface information is written |
This operation subscribe provided interface in the ConnectorProfile.
connector_profile | The ConnectorProfile that includes provided interface information |
This operation unsubscribe provided interface in the ConnectorProfile.
connector_profile | The ConnectorProfile of unsubscribed connection |
Reimplemented from RTC::OutPortBase.
virtual void RTC::OutPort< DataType >::onDisconnect | ( | const char * | id | ) | [inline, virtual] |
Reimplemented from RTC::OutPortBase.