A QoS Profile may include configuration settings for all types of Entities. If you just want the settings for a specific type of Entity, call get_<entity>_qos_from_profile() (where <entity> may be participant, publisher, subscriber, datawriter, datareader, or topic). This is useful if you want to get the QoS values from the profile in a structure, make some changes, and then use that structure to create an entity.
DDS_ReturnCode_t get_<entity>_qos_from_profile ( DDS_<Entity>Qos &qos, const char *library_name, const char *profile_name)
For an example, see Getting QoS Values from a Profile, Changing QoS Values, Creating a Publisher with Modified QoS Values.
The get_<entity>_qos_from_profile() operations do not take into account the topic_filter attributes that may be set for DataWriter, DataReader, or Topic QoSs in profiles (see Topic Filters). If there is a topic name associated with an entity, you can call get_<entity>_qos_from_profile_w_topic_name() (where <entity> can be datawriter, datareader, or topic) and the topic filter expressions in the profile will be evaluated on the topic name.
DDS_ReturnCode_t get_<entity>_qos_from_profile_w_topic_name(
DDS_<entity>Qos &qos,
const char *library_name,
const char *profile_name,
const char *topic_name)
get_<entity>_qos_from_profile() and get_<entity>_qos_from_profile_w_topic_name() may allocate memory, depending on the sequences contained in some QoS policies.
Note: in the Modern C++ API, the class QosProvider provides the functionality described in thi section. Please see the API Reference HTML documentation: Modules, RTI Connext DDS API Reference, Configuring QoS Profiles with XML, QosProvider.
© 2016 RTI