Public Types | Public Member Functions | Private Attributes
RTT::internal::ChannelDataElement< T > Class Template Reference

#include <ChannelDataElement.hpp>

Inheritance diagram for RTT::internal::ChannelDataElement< T >:
Inheritance graph
[legend]

List of all members.

Public Types

typedef base::ChannelElement
< T >::param_t 
param_t
typedef base::ChannelElement
< T >::reference_t 
reference_t

Public Member Functions

 ChannelDataElement (typename base::DataObjectInterface< T >::shared_ptr sample)
virtual void clear ()
virtual bool data_sample (param_t sample)
virtual T data_sample ()
virtual FlowStatus read (reference_t sample, bool copy_old_data)
virtual bool write (param_t sample)

Private Attributes

base::DataObjectInterface< T >
::shared_ptr 
data
bool mread
bool written

Detailed Description

template<typename T>
class RTT::internal::ChannelDataElement< T >

A connection element that stores a single data sample

Definition at line 50 of file ChannelDataElement.hpp.


Member Typedef Documentation

Reimplemented from RTT::base::ChannelElement< T >.

Definition at line 56 of file ChannelDataElement.hpp.

Reimplemented from RTT::base::ChannelElement< T >.

Definition at line 57 of file ChannelDataElement.hpp.


Constructor & Destructor Documentation

template<typename T>
RTT::internal::ChannelDataElement< T >::ChannelDataElement ( typename base::DataObjectInterface< T >::shared_ptr  sample) [inline]

Definition at line 59 of file ChannelDataElement.hpp.


Member Function Documentation

template<typename T>
virtual void RTT::internal::ChannelDataElement< T >::clear ( ) [inline, virtual]

Resets the stored sample. After clear() has been called, read() returns false

Reimplemented from RTT::base::ChannelElementBase.

Definition at line 97 of file ChannelDataElement.hpp.

template<typename T>
virtual bool RTT::internal::ChannelDataElement< T >::data_sample ( param_t  sample) [inline, virtual]

Provides a data sample to initialize this connection. This is used before the first write() in order to inform this connection of the size of the data. As such enough storage space can be allocated before the actual writing begins.

Returns:
false if an error occured that requires the channel to be invalidated.

Reimplemented from RTT::base::ChannelElement< T >.

Definition at line 104 of file ChannelDataElement.hpp.

template<typename T>
virtual T RTT::internal::ChannelDataElement< T >::data_sample ( ) [inline, virtual]

Reimplemented from RTT::base::ChannelElement< T >.

Definition at line 110 of file ChannelDataElement.hpp.

template<typename T>
virtual FlowStatus RTT::internal::ChannelDataElement< T >::read ( reference_t  sample,
bool  copy_old_data 
) [inline, virtual]

Reads the last sample given to write()

Returns:
false if no sample has ever been written, true otherwise

Reimplemented from RTT::base::ChannelElement< T >.

Definition at line 76 of file ChannelDataElement.hpp.

template<typename T>
virtual bool RTT::internal::ChannelDataElement< T >::write ( param_t  sample) [inline, virtual]

Update the data sample stored in this element. It always returns true.

Reimplemented from RTT::base::ChannelElement< T >.

Definition at line 64 of file ChannelDataElement.hpp.


Member Data Documentation

Definition at line 53 of file ChannelDataElement.hpp.

template<typename T>
bool RTT::internal::ChannelDataElement< T >::mread [private]

Definition at line 52 of file ChannelDataElement.hpp.

template<typename T>
bool RTT::internal::ChannelDataElement< T >::written [private]

Definition at line 52 of file ChannelDataElement.hpp.


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


rtt
Author(s): RTT Developers
autogenerated on Thu Jan 2 2014 11:35:44