RTI Connext Traditional C++ API Version 7.1.0

Infrastructure types for RTI Connext Messaging. More...

Modules

 RTI Connext Exceptions
 RTI Connext return-code exceptions.
 

Classes

class  connext::Sample< T >
 A data sample and related info received from the middleware. More...
 
class  connext::SampleRef< T >
 A data sample and related information received from the middleware. More...
 
class  connext::WriteSample< T >
 A sample for writing data. More...
 
class  connext::WriteSampleRef< T >
 A reference to a data sample for writing. More...
 
class  connext::IsValidSamplePredicate< T >
 Predicate-class to determine if a sample contains valid data. More...
 
class  connext::IsInvalidSamplePredicate< T >
 Predicate-class to determine if a sample contains invalid data. More...
 
class  connext::IsReplyRelatedPredicate< T >
 Predicate-class to match replies by their related request. More...
 
class  connext::SampleIterator< T, IsConst >
 STL-compliant random-access iterator for SampleRef<T> More...
 
class  connext::LoanedSamples< T >
 Provides access to a collection of middleware-loaned samples. More...
 

Functions

template<typename T , bool IsConst>
ValidSampleIterator< T, IsConst > connext::make_valid_sample_iterator (SampleIterator< T, IsConst > related_iterator)
 Creates an iterator that only returns valid samples. More...
 
template<typename T >
LoanedSamples< T > connext::move (LoanedSamples< T > &ls) throw ()
 Creates a new LoanedSamples instance by moving the contents of an existing one. More...
 

Detailed Description

Infrastructure types for RTI Connext Messaging.

This section describes the sample types used for reading and writing. These types encapsulate data and related information:

Sample and WriteSample are value types. They own the data and the related information and their constructor and destructor initializes and releases the data types.

There are two parallel versions that behave as reference types and hold references to existing data and information instances:

There are different operations that provide loaned samples from the middleware. They return a connext::LoanedSamples. This container provides STL-compliant iterators.

Other convenience functions and types, useful in combination with STL algorithms are:

Function Documentation

◆ make_valid_sample_iterator()

template<typename T , bool IsConst>
ValidSampleIterator< T, IsConst > connext::make_valid_sample_iterator ( SampleIterator< T, IsConst >  related_iterator)

Creates an iterator that only returns valid samples.

This operation returns an iterator adapter that behaves as the associated connext::SampleIterator expect that it skips samples where SampleRef::info().valid_data is false

Parameters
related_iteratorA regular SampleIterator (e.g. connext::LoanedSamples::begin) that serves as the start point.
Returns
An iterator pointing to the first valid sample on or after related_iterator or the end of the associated connext::LoanedSamples if there are no valid samples.
See also
connext::LoanedSamples::begin
Taking samples by copy

◆ move()

template<typename T >
LoanedSamples< T > connext::move ( LoanedSamples< T > &  ls)
throw (
)

Creates a new LoanedSamples instance by moving the contents of an existing one.

   The parameter object looses the ownership of the underlying samples and its state 
   is reset as if it was default initialized. This function must be used to move 
   any named LoanedSamples instance (lvalue) in and out of a function by-value. 
   Using this function is not necessary if the original LoanedSamples is an rvalue. 
   Moving is a very efficient operation and is guaranteed to not throw any exception.
Parameters
lsThe LoanedSamples object that transfers its ownership of the contained samples into the returned object. After this call, ls is empty.
Returns
A new LoanedSamples object, the new loan owner, with the same contents as ls had.
See also
connext::LoanedSamples