|
RTI Connext Modern C++ API Version 7.6.0
|
Provides a DynamicType that represents an IDL-generated type. More...
#include <rti/topic/TopicTraits.hpp>
Provides a DynamicType that represents an IDL-generated type.
This type is specialized for IDL-generated types to provide a get() function whose return type is a const reference to a concrete subclass of dds::core::xtypes::DynamicType, such as dds::core::xtypes::StructType, dds::core::xtypes::UnionType, dds::core::xtypes::EnumType.
For example, given the following IDL type Foo:
You can obtain its DynamicType (in this case a StructType) as follows:
Note that if the type is an IDL alias such as the following:
Then rti::topic::dynamic_type<Bar> resolves to rti::topic::dynamic_type<Foo>, both returning the same StructType. If you want to explicitly access the AliasType use the special tag type Bar_AliasTag_t: