RTI Connext Modern C++ API
Version 6.0.1
|
<<reference-type>> This class provides an non-template holder for representing a DataReader of any type More...
#include "dds/sub/AnyDataReader.hpp"
Public Member Functions | |
template<typename T > | |
AnyDataReader (const dds::sub::DataReader< T > &reader) | |
Create an AnyDataReader that represents a generic, untyped DataReader. | |
dds::sub::qos::DataReaderQos | qos () const |
Get the QoS for this AnyDataReader. | |
void | qos (const dds::sub::qos::DataReaderQos &the_qos) |
Set the QoS for this AnyDataReader. | |
const std::string & | topic_name () const |
Get the topic name for this AnyDataReader. | |
const std::string & | type_name () const |
Get the type name for this AnyDataReader. | |
const dds::sub::Subscriber & | subscriber () const |
Get the publisher for this AnyDataReader. | |
template<typename T > | |
AnyDataReader & | operator= (const DataReader< T > &other) |
Assign a different DataReader. | |
template<typename T > | |
dds::sub::DataReader< T > | get () const |
Gets the typed DataReader from this AnyDataReader. | |
void | close () |
Close this AnyDataReader. | |
void | retain () |
Retain this AnyDataReader. | |
Related Functions | |
(Note that these are not member functions.) | |
template<typename T > | |
DataReader< T > | get (const AnyDataReader &any_reader) |
Same as AnyDataReader::get() | |
<<reference-type>> This class provides an non-template holder for representing a DataReader of any type
This class is useful for code that uses DataReaders of different types. It provides access to type-independent DataReader functions.
An AnyDataReader is always created from a typed DataReader, increasing its reference count. The member function get() allows getting the typed DataReader back.
|
inline |
Create an AnyDataReader that represents a generic, untyped DataReader.
T | The type of the DataReader that this AnyDataReader is being created from |
reader | The typed DataReader that this AnyDataReader will represent |
|
inline |
Get the QoS for this AnyDataReader.
|
inline |
Set the QoS for this AnyDataReader.
the_qos | The QoS to set |
|
inline |
Get the topic name for this AnyDataReader.
|
inline |
Get the type name for this AnyDataReader.
|
inline |
Get the publisher for this AnyDataReader.
|
inline |
Assign a different DataReader.
Replaces the reference to the current reader with a new one, whose type T
can be different.
|
inline |
Gets the typed DataReader from this AnyDataReader.
T | The type of the DataReader to extract |
dds::core::InvalidDowncastError | If this AnyDataReader doesn't represent a DataReader<T>. |
|
inline |
Close this AnyDataReader.
|
inline |
Retain this AnyDataReader.
|
related |
Same as AnyDataReader::get()