RTI Connext Modern C++ API Version 7.2.0
|
<<extension>> <<value-type>> A collection of attributes used to configure how QoS will be formatted when converted to strings. More...
#include <rti/core/QosPrintFormat.hpp>
Public Member Functions | |
QosPrintFormat () | |
Initializes the properties with the default values. More... | |
QosPrintFormat (unsigned int indent_in, bool print_private_in, bool is_standalone_in) | |
Initializes the properties. More... | |
unsigned int | indent () const |
Get the value of indent. More... | |
QosPrintFormat & | indent (unsigned int value) |
Set the amount of additional indent to be included when converting a QoS to a string. More... | |
bool | print_private () const |
Get the value of print_private. More... | |
QosPrintFormat & | print_private (bool value) |
Set whether or not to print private Qos fields. More... | |
bool | is_standalone () const |
Get the value of is_standalone. More... | |
QosPrintFormat & | is_standalone (bool value) |
Set whether or not to print the XML preamble. More... | |
<<extension>> <<value-type>> A collection of attributes used to configure how QoS will be formatted when converted to strings.
|
inline |
Initializes the properties with the default values.
|
inline |
Initializes the properties.
|
inline |
Get the value of indent.
|
inline |
Set the amount of additional indent to be included when converting a QoS to a string.
Configures how much additional indent is applied when converting a QoS to a string. This value acts as a total offset on the string, increasing the indent which is applied to all elements by the same amount. With indent set to 0, a string representation of a QoS may appear as:
<datareader_qos> <durability> <kind>TRANSIENT_LOCAL_DURABILITY_QOS</kind> </durability> </datareader_qos>
Setting the indent property to 1, the same QoS would be printed as:
<datareader_qos> <durability> <kind>TRANSIENT_LOCAL_DURABILITY_QOS</kind> </durability> </datareader_qos>
I.e., the entire structure is indented.
[default] 0
value | The value to set for indent |
|
inline |
Get the value of print_private.
|
inline |
Set whether or not to print private Qos fields.
There are some QoS policies which are not intended for external use. By default, these QoS policies are only printed if they are different to the default value for that policy. When true, private policies are treated like any other policy, and printed if they are different to the supplied base QoS. These private policies cannot be parsed from XML, and are always printed as XML comments.
[default] false
value | The value to set for print_private. |
|
inline |
Get the value of is_standalone.
|
inline |
Set whether or not to print the XML preamble.
The default value for this property (false) results in QoS being printed starting from the <ENTITY_qos> tag (where the <ENTITY_qos> tag is, e.g., <domain_participant_qos>, or, <datareader_qos>. This result cannot be directly parsed as valid XML (as it lacks <dds>, <qos_library>, and <qos_profile> tags). If is_standalone is set to true, these additional tags are printed, resulting in valid, parseable XML.
For example, with is_standalone set to false, a Qos may appear as:
<datareader_qos> <durability> <kind>TRANSIENT_LOCAL_DURABILITY_QOS</kind> </durability> </datareader_qos>
Setting is_standalone to true would result in the same Qos being printed as:
<?xml version="1.0"?> <dds xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance"> <qos_library name="QosLibrary"> <qos_profile name="QosProfile"> <datareader_qos> <durability> <kind>TRANSIENT_LOCAL_DURABILITY_QOS</kind> </durability> </datareader_qos> </qos_profile> </qos_library> </dds>
[default] false
value | The value to set for is_standalone. |