Skip to content

Commit

Permalink
Refs #21077: Revision
Browse files Browse the repository at this point in the history
Signed-off-by: cferreiragonz <[email protected]>
  • Loading branch information
cferreiragonz committed Jun 18, 2024
1 parent 5c801a6 commit 04b2e35
Show file tree
Hide file tree
Showing 4 changed files with 56 additions and 73 deletions.
39 changes: 19 additions & 20 deletions code/DDSCodeTester.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -3971,8 +3971,7 @@ void dds_qos_examples()
{
// Taken out of the examples to avoid bloating them
DomainParticipantFactory* factory_ = DomainParticipantFactory::get_instance();
DomainParticipant* participant_ =
DomainParticipantFactory::get_instance()->create_participant(0, PARTICIPANT_QOS_DEFAULT);
DomainParticipant* participant_ = factory_->create_participant(0, PARTICIPANT_QOS_DEFAULT);
Subscriber* subscriber_ =
participant_->create_subscriber(SUBSCRIBER_QOS_DEFAULT);
Publisher* publisher_ =
Expand All @@ -3984,9 +3983,9 @@ void dds_qos_examples()
uint16_t domain = 7;
{
//DDS_CHANGE_DEADLINE_QOS_POLICY
// This example uses a DataWriter, but it can also be applied to: DataWriter, DataReader and Topic entities
// This example uses a DataWriter, but it can also be applied to DataReader and Topic entities
DataWriterQos writer_qos;
// The DeadlineQosPolicy is default constructed with an infinite period.
// The DeadlineQosPolicy is constructed with an infinite period by default
// Change the period to 1 second
writer_qos.deadline().period.seconds = 1;
writer_qos.deadline().period.nanosec = 0;
Expand All @@ -3997,7 +3996,7 @@ void dds_qos_examples()

{
//DDS_CHANGE_DURABILITY_QOS_POLICY
// This example uses a DataWriter, but it can also be applied to: DataWriter, DataReader and Topic entities
// This example uses a DataWriter, but it can also be applied to DataReader and Topic entities
DataWriterQos writer_qos;
// The DurabilityQosPolicy is default constructed with kind = VOLATILE_DURABILITY_QOS
// Change the kind to TRANSIENT_LOCAL_DURABILITY_QOS
Expand All @@ -4009,8 +4008,8 @@ void dds_qos_examples()

{
//DDS_CHANGE_ENTITY_FACTORY_QOS_POLICY
// This example uses a Participant, but it can also be applied to:
// DomainParticipantFactory, DomainParticipant, Publisher and Subscriber entities
// This example uses a Participant, but it can also be applied to
// DomainParticipantFactory, Publisher and Subscriber entities
DomainParticipantQos participant_qos;
// The EntityFactoryQosPolicy is default constructed with autoenable_created_entities = true
// Change it to false
Expand All @@ -4022,7 +4021,7 @@ void dds_qos_examples()

{
//DDS_CHANGE_GROUP_DATA_QOS_POLICY
// This example uses a Publisher, but it can also be applied to: Publisher and Subscriber entities
// This example uses a Publisher, but it can also be applied to Subscriber entities
PublisherQos publisher_qos;
// The GroupDataQosPolicy is default constructed with an empty collection
// Collection is a private member so you need to use getters and setters to access
Expand Down Expand Up @@ -4050,7 +4049,7 @@ void dds_qos_examples()

{
//DDS_CHANGE_HISTORY_QOS_POLICY
// This example uses a DataWriter, but it can also be applied to: DataWriter, DataReader and Topic entities
// This example uses a DataWriter, but it can also be applied to DataReader and Topic entities
DataWriterQos writer_qos;
// The HistoryQosPolicy is default constructed with kind = KEEP_LAST and depth = 1.
// It is possible to adjust the depth and keep the kind as KEEP_LAST
Expand All @@ -4064,7 +4063,7 @@ void dds_qos_examples()

{
//DDS_CHANGE_LIFESPAN_QOS_POLICY
// This example uses a DataWriter, but it can also be applied to: DataWriter, DataReader and Topic entities
// This example uses a DataWriter, but it can also be applied to DataReader and Topic entities
DataWriterQos writer_qos;
// The LifespanQosPolicy is default constructed with duration set to infinite.
// Change the duration to 5 s
Expand All @@ -4076,7 +4075,7 @@ void dds_qos_examples()

{
//DDS_CHANGE_LIVELINESS_QOS_POLICY
// This example uses a DataWriter, but it can also be applied to: DataWriter, DataReader and Topic entities
// This example uses a DataWriter, but it can also be applied to DataReader and Topic entities
DataWriterQos writer_qos;
// The LivelinessQosPolicy is default constructed with kind = AUTOMATIC
// Change the kind to MANUAL_BY_PARTICIPANT
Expand All @@ -4094,7 +4093,7 @@ void dds_qos_examples()

{
//DDS_CHANGE_OWNERSHIP_QOS_POLICY
// This example uses a DataWriter, but it can also be applied to: DataWriter, DataReader and Topic entities
// This example uses a DataWriter, but it can also be applied to DataReader and Topic entities
DataWriterQos writer_qos;
// The OwnershipQosPolicy is default constructed with kind = SHARED.
// Change the kind to EXCLUSIVE
Expand All @@ -4118,7 +4117,7 @@ void dds_qos_examples()

{
//DDS_CHANGE_PARTITION_QOS_POLICY
// This example uses a Publisher, but it can also be applied to: Publisher and Subscriber entities
// This example uses a Publisher, but it can also be applied to Subscriber entities
PublisherQos publisher_qos;
// The PartitionsQosPolicy is default constructed with max_size = 0
// Max_size is a private member so you need to use getters and setters to access
Expand Down Expand Up @@ -4146,7 +4145,7 @@ void dds_qos_examples()

{
//DDS_CHANGE_RELIABILITY_QOS_POLICY
// This example uses a DataWriter, but it can also be applied to: DataWriter, DataReader and Topic entities
// This example uses a DataWriter, but it can also be applied to DataReader and Topic entities
DataWriterQos writer_qos;
// The ReliabilityQosPolicy is default constructed with kind = BEST_EFFORT
// Change the kind to RELIABLE
Expand All @@ -4161,7 +4160,7 @@ void dds_qos_examples()

{
//DDS_CHANGE_RESOURCE_LIMITS_QOS_POLICY
// This example uses a DataWriter, but it can also be applied to: DataWriter, DataReader and Topic entities
// This example uses a DataWriter, but it can also be applied to DataReader and Topic entities
DataWriterQos writer_qos;
// The ResourceLimitsQosPolicy is default constructed with max_samples = 5000
// Change max_samples to 200
Expand Down Expand Up @@ -4199,7 +4198,7 @@ void dds_qos_examples()

{
//DDS_CHANGE_USER_DATA_QOS_POLICY
// This example uses a DataWriter, but it can also be applied to: DomainParticipant, DataWriter, and DataReader entities
// This example uses a DataWriter, but it can also be applied to DomainParticipant and DataReader entities
DataWriterQos writer_qos;
std::vector<eprosima::fastrtps::rtps::octet> vec;
// Add two new octets to user data vector
Expand All @@ -4215,7 +4214,7 @@ void dds_qos_examples()

{
//DDS_CHANGE_DATASHARING_QOS_POLICY
// This example uses a DataWriter, but it can also be applied to: DataWriter and DataReader entities
// This example uses a DataWriter, but it can also be applied to DataReader entities
DataWriterQos writer_qos;

// DataSharing is set to AUTO by default, which means that DataSharing will be used if the topic
Expand Down Expand Up @@ -4346,7 +4345,7 @@ void dds_qos_examples()

{
//DDS_CHANGE_PROPERTY_POLICY_QOS
// This example uses a DataWriter, but it can also be applied to: DomainParticipant, DataWriter and DataReader entities
// This example uses a DataWriter, but it can also be applied to DomainParticipant and DataReader entities
DataWriterQos writer_qos;
// Add new property for the Auth:PKI-DH plugin
writer_qos.properties().properties().emplace_back("dds.sec.auth.plugin", "builtin.PKI-DH");
Expand Down Expand Up @@ -4409,7 +4408,7 @@ void dds_qos_examples()

{
//DDS_CHANGE_RTPS_ENDPOINT_QOS
// This example uses a DataWriter, but it can also be applied to: DataWriter and DataReader entities
// This example uses a DataWriter, but it can also be applied to DataReader entities
DataWriterQos writer_qos;
// Add new unicast locator with port 7800
eprosima::fastrtps::rtps::Locator_t new_unicast_locator;
Expand Down Expand Up @@ -4564,7 +4563,7 @@ void dds_qos_examples()

{
//DDS_CHANGE_DATA_REPRESENTATION_QOS
// This example uses a DataWriter, but it can also be applied to: DataWriter and Topic entities.
// This example uses a DataWriter, but it can also be applied to Topic entities.
// DataRepresentationQosPolicy of DataReaders is contained in the TypeConsistencyQos
// (for further details see TypeConsistencyQos section).
DataWriterQos writer_qos;
Expand Down
26 changes: 13 additions & 13 deletions docs/fastdds/dds_layer/core/policy/eprosimaExtensions.rst
Original file line number Diff line number Diff line change
Expand Up @@ -75,7 +75,7 @@ List of QoS Policy data members:
The |ThreadSettings| for the data-sharing thread dedicated to listening for incoming traffic.

.. note::
This QoS Policy concerns to |DataWriter| and |DataReader| entities.
This QoS Policy applies to |DataWriter| and |DataReader| entities.
:raw-html:`<br />`
It cannot be changed on enabled entities.

Expand Down Expand Up @@ -176,7 +176,7 @@ List of QoS Policy data members:
This value does not apply to DataReaders.

.. note::
This QoS Policy concerns to |DataWriter| and |DataReader| entities.
This QoS Policy applies to |DataWriter| and |DataReader| entities.
:raw-html:`<br />`
The |DisablePositiveACKsQosPolicy::enabled-api| Data Member cannot be modified on enabled entities.
Thus, this feature must be set up during initialization.
Expand Down Expand Up @@ -252,7 +252,7 @@ List of QoS Policy data members:
See :ref:`disablepositiveacksqospolicy` for further details.

.. note::
This QoS Policy concerns to |DataReader| entities.
This QoS Policy applies to |DataReader| entities.
:raw-html:`<br />`
Only the |DisablePositiveACKsQosPolicy::duration-api| Data Member of the :ref:`disablepositiveacksqospolicy` and the |RTPSReliableReaderQos::times-api|
Data Member can be modified on enabled entities.
Expand Down Expand Up @@ -332,7 +332,7 @@ List of QoS Policy data members:
See :ref:`disableheartbeatpiggyback` for further details.

.. note::
This QoS Policy concerns to |DataWriter| entities.
This QoS Policy applies to |DataWriter| entities.
:raw-html:`<br />`
Only the |DisablePositiveACKsQosPolicy::duration-api| Data Member of the :ref:`disablepositiveacksqospolicy` and the |RTPSReliableWriterQos::times-api|
Data Member can be modified on enabled entities.
Expand Down Expand Up @@ -441,7 +441,7 @@ Please refer to :ref:`flow-controllers` section for more information.


.. note::
This QoS Policy concerns to |DomainParticipant| entities.
This QoS Policy applies to |DomainParticipant| entities.
:raw-html:`<br />`
It cannot be changed on enabled entities.

Expand Down Expand Up @@ -492,7 +492,7 @@ List of QoS Policy data members:
States the limits for content-filter discovery information.

.. note::
This QoS Policy concerns to |DomainParticipant| entities.
This QoS Policy applies to |DomainParticipant| entities.
:raw-html:`<br />`
It cannot be changed on enabled entities.

Expand Down Expand Up @@ -687,7 +687,7 @@ This QoS also allows to add custom user properties that could be sent to the ext
This could be done by setting as :code:`true` the :code:`propagate` value of the Property.

.. note::
This QoS Policy concerns to |DomainParticipant|, |DataWriter| and |DataReader| entities.
This QoS Policy applies to |DomainParticipant|, |DataWriter| and |DataReader| entities.
:raw-html:`<br />`
It cannot be changed on enabled entities.

Expand Down Expand Up @@ -740,7 +740,7 @@ List of QoS Policy data members:
- |FASTDDS_FLOW_CONTROLLER_DEFAULT-api|

.. note::
This QoS Policy concerns to |DataWriter| entities.
This QoS Policy applies to |DataWriter| entities.
:raw-html:`<br />`
It cannot be changed on enabled entities.

Expand Down Expand Up @@ -797,7 +797,7 @@ List of QoS Policy data members:


.. note::
This QoS Policy concerns to |DataReader| entities.
This QoS Policy applies to |DataReader| entities.
:raw-html:`<br />`
It cannot be changed on enabled entities.

Expand Down Expand Up @@ -841,7 +841,7 @@ List of QoS Policy data members:
+-----------------------------------------------------------------------------+----------------------------------------+

.. note::
This QoS Policy concerns to |DataWriter| entities.
This QoS Policy applies to |DataWriter| entities.
:raw-html:`<br />`
It cannot be changed on enabled entities.

Expand Down Expand Up @@ -929,7 +929,7 @@ List of QoS Policy data members:
Indicates the way the memory is managed in terms of dealing with the CacheChanges.

.. note::
This QoS Policy concerns to |DataWriter| and |DataReader| entities.
This QoS Policy applies to |DataWriter| and |DataReader| entities.
:raw-html:`<br />`
It cannot be changed on enabled entities.

Expand Down Expand Up @@ -1119,7 +1119,7 @@ List of QoS Policy data members:
:ref:`Network filter<netmask_filtering>` configuration.

.. note::
This QoS Policy concerns to |DomainParticipant| entities.
This QoS Policy applies to |DomainParticipant| entities.
:raw-html:`<br />`
It cannot be changed on enabled entities.

Expand Down Expand Up @@ -1236,7 +1236,7 @@ List of QoS Policy data members:
any of the locators announced by this DDS participant.

.. note::
This QoS Policy concerns to |DomainParticipant| entities.
This QoS Policy applies to |DomainParticipant| entities.

.. important::
The only mutable field on enabled entities is |m_DiscoveryServers|, which is contained in
Expand Down
Loading

0 comments on commit 04b2e35

Please sign in to comment.