Skip to content

Commit

Permalink
Move DR TypeConsistencyEnforcement & DataRepresentation from TypeCons…
Browse files Browse the repository at this point in the history
…istency to DataReaderQos (#779)

* Refs #21053: Move DR TypeConsistencyEnforcementQosPolicy & DataRepresentationQosPolicy to correct place

Signed-off-by: JesusPoderoso <[email protected]>

* Refs #21053: Apply rev suggestions

Signed-off-by: JesusPoderoso <[email protected]>

---------

Signed-off-by: JesusPoderoso <[email protected]>
  • Loading branch information
JesusPoderoso authored May 27, 2024
1 parent e9b2984 commit 4119d79
Show file tree
Hide file tree
Showing 11 changed files with 20 additions and 87 deletions.
10 changes: 0 additions & 10 deletions code/DDSCodeTester.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -4431,16 +4431,6 @@ void dds_qos_examples()
//!--
}

{
//DDS_CHANGE_TYPE_CONSISTENCY_QOS
TypeConsistencyQos consistency_qos;
//You can change the DataRepresentationQosPolicy. For further details see DataRepresentationQosPolicySection section.
consistency_qos.representation.m_value.push_back(DataRepresentationId_t::XCDR2_DATA_REPRESENTATION);
//You can change the TypeConsistencyEnforcementQosPolicy. For further details see TypeConsistencyEnforcementQosPolicy section.
consistency_qos.type_consistency.m_kind = TypeConsistencyKind::ALLOW_TYPE_COERCION;
//!--
}

// Taken out of the examples to avoid bloating them
DomainParticipant* participant =
DomainParticipantFactory::get_instance()->create_participant(0, PARTICIPANT_QOS_DEFAULT);
Expand Down
5 changes: 1 addition & 4 deletions docs/03-exports/aliases-api.include
Original file line number Diff line number Diff line change
Expand Up @@ -65,6 +65,7 @@
.. |DataReaderQos::resource_limits-api| replace:: :cpp:func:`resource_limits()<eprosima::fastdds::dds::DataReaderQos::resource_limits>`
.. |DataReaderQos::time_based_filter-api| replace:: :cpp:func:`time_based_filter()<eprosima::fastdds::dds::DataReaderQos::time_based_filter>`
.. |DataReaderQos::type_consistency-api| replace:: :cpp:func:`type_consistency()<eprosima::fastdds::dds::DataReaderQos::type_consistency>`
.. |DataReaderQos::representation-api| replace:: :cpp:func:`representation()<eprosima::fastdds::dds::DataReaderQos::representation>`
.. |DataReaderQos::user_data-api| replace:: :cpp:func:`user_data()<eprosima::fastdds::dds::DataReaderQos::user_data>`

.. |DataReaders-api| replace:: :cpp:class:`DataReaders <eprosima::fastdds::dds::DataReader>`
Expand Down Expand Up @@ -693,10 +694,6 @@
.. |SharedMemTransportDescriptor::rtps_dump_file-api| replace:: :cpp:func:`rtps_dump_file()<eprosima::fastdds::rtps::SharedMemTransportDescriptor::rtps_dump_file>`
.. |SharedMemTransportDescriptor::dump_thread-api| replace:: :cpp:func:`dump_thread()<eprosima::fastdds::rtps::SharedMemTransportDescriptor::dump_thread>`

.. |TypeConsistencyQos-api| replace:: :cpp:class:`TypeConsistencyQos<eprosima::fastdds::dds::TypeConsistencyQos>`
.. |TypeConsistencyQos::type_consistency-api| replace:: :cpp:member:`type_consistency<eprosima::fastdds::dds::TypeConsistencyQos::type_consistency>`
.. |TypeConsistencyQos::representation-api| replace:: :cpp:member:`representation<eprosima::fastdds::dds::TypeConsistencyQos::representation>`

.. |WireProtocolConfigQos-api| replace:: :cpp:class:`WireProtocolConfigQos<eprosima::fastdds::dds::WireProtocolConfigQos>`
.. |WireProtocolConfigQos::prefix-api| replace:: :cpp:member:`prefix<eprosima::fastdds::dds::WireProtocolConfigQos::prefix>`
.. |WireProtocolConfigQos::participant_id-api| replace:: :cpp:member:`participant_id<eprosima::fastdds::dds::WireProtocolConfigQos::participant_id>`
Expand Down
1 change: 0 additions & 1 deletion docs/03-exports/aliases.include
Original file line number Diff line number Diff line change
Expand Up @@ -82,7 +82,6 @@
.. |TransportConfigQos| replace:: :ref:`TransportConfigQos<transportconfigqos>`
.. |TransportPriorityQosPolicy| replace:: :ref:`TransportPriorityQosPolicy<transportpriorityqospolicy>`
.. |TypeConsistencyEnforcementQosPolicy| replace:: :ref:`TypeConsistencyEnforcementQosPolicy<typeconsistencyenforcementqospolicy>`
.. |TypeConsistencyQos| replace:: :ref:`TypeConsistencyQos<typeconsistencyqos>`
.. |TypeInformation| replace:: :ref:`TypeInformation<xtypes_discovery_matching>`
.. |TypeObject| replace:: :ref:`TypeObject representation<xtypes_discovery_matching>`
.. |UserDataQosPolicy| replace:: :ref:`UserDataQosPolicy<userdataqospolicy>`
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -16,5 +16,4 @@ Subscriber
/fastdds/api_reference/dds_pim/subscriber/subscriber_class.rst
/fastdds/api_reference/dds_pim/subscriber/subscriberlistener.rst
/fastdds/api_reference/dds_pim/subscriber/subscriberqos.rst
/fastdds/api_reference/dds_pim/subscriber/typeconsistencyqos.rst
/fastdds/api_reference/dds_pim/subscriber/viewstatekind.rst

This file was deleted.

1 change: 0 additions & 1 deletion docs/fastdds/api_reference/spelling_wordlist.txt
Original file line number Diff line number Diff line change
Expand Up @@ -271,7 +271,6 @@ TopicListener
TransportDescriptor
TransportPriorityQosPolicy
TypeConsistencyEnforcementQosPolicy
TypeConsistencyQos
typedef
typeid
TypeIdentfierWithSizePubSubType
Expand Down
45 changes: 0 additions & 45 deletions docs/fastdds/dds_layer/core/policy/eprosimaExtensions.rst
Original file line number Diff line number Diff line change
Expand Up @@ -1071,51 +1071,6 @@ XML
transports configuration by selecting one of the available builtin transports options.
See :ref:`rtps_layer_builtin_transports` or |DomainParticipantQoS::setup_transports-api|.

.. _typeconsistencyqos:

TypeConsistencyQos
^^^^^^^^^^^^^^^^^^

This QoS Policy allows the configuration of the :ref:`XTypes extension QoS<xtypes_extensions>` on the |DataReader|.
See |TypeConsistencyQos-api|.

List of QoS Policy data members:

+-------------------------------------------------------------------------+--------------------------------------------+
| Data Member Name | Type |
+=========================================================================+============================================+
| |TypeConsistencyQos::type_consistency-api| | :ref:`typeconsistencyenforcementqospolicy` |
+-------------------------------------------------------------------------+--------------------------------------------+
| |TypeConsistencyQos::representation-api| | :ref:`datarepresentationqospolicy` |
+-------------------------------------------------------------------------+--------------------------------------------+

* |TypeConsistencyQos::type_consistency-api|:
It states the rules for the data types compatibility.
See :ref:`typeconsistencyenforcementqospolicy` for further details.
* |TypeConsistencyQos::representation-api|:
It specifies the data representations valid for the entities.
See :ref:`datarepresentationqospolicy` for further details.

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

Example
"""""""

C++
***
.. literalinclude:: ../../../../../code/DDSCodeTester.cpp
:language: c++
:dedent: 8
:start-after: //DDS_CHANGE_TYPE_CONSISTENCY_QOS
:end-before: //!

XML
***
This QoS Policy cannot be configured using XML for the moment.

.. _wireprotocolconfigqos:

WireProtocolConfigQos
Expand Down
21 changes: 16 additions & 5 deletions docs/fastdds/dds_layer/core/policy/xtypesExtensions.rst
Original file line number Diff line number Diff line change
@@ -1,5 +1,6 @@
.. include:: ../../../../03-exports/aliases.include
.. include:: ../../../../03-exports/aliases-api.include
.. include:: ../../../../03-exports/roles.include

.. role:: raw-html(raw)
:format: html
Expand Down Expand Up @@ -31,11 +32,21 @@ See |DataRepresentationQosPolicy-api|.

List of QoS Policy data members:

+-----------------------------------------------------------+------------------------------------------+---------------+
| Data Member Name | Type | Default Value |
+===========================================================+==========================================+===============+
| |DataRepresentationQosPolicy::m_value-api| | std::vector<:ref:`datarepresentationid`> | Empty vector |
+-----------------------------------------------------------+------------------------------------------+---------------+
.. list-table::
:header-rows: 1

* - Data Member Name
- Type
- Default Value
- DataReader default value
- DataWriter default value
- Topic default value
* - |DataRepresentationQosPolicy::m_value-api|
- std::vector<:ref:`datarepresentationid`>
- Empty vector
- [|XCDR_DATA_REPRESENTATION-api|, |br| |XCDR2_DATA_REPRESENTATION-api|]
- [|XCDR2_DATA_REPRESENTATION-api|]
- [|XCDR_DATA_REPRESENTATION-api|]

.. note::
This QoS Policy concerns to Topic, DataReader and DataWriter entities.
Expand Down
4 changes: 3 additions & 1 deletion docs/fastdds/dds_layer/subscriber/dataReader/dataReader.rst
Original file line number Diff line number Diff line change
Expand Up @@ -72,7 +72,9 @@ Internally it contains the following |QosPolicy-api| objects:
+-----------------------------------------------+---------------------------------------------+----------+
| |RTPSreliablereaderqos| | |DataReaderQos::reliable_reader_qos-api| | Yes (*) |
+-----------------------------------------------+---------------------------------------------+----------+
| |typeconsistencyqos| | |DataReaderQos::type_consistency-api| | Yes |
| |typeconsistencyenforcementqospolicy| | |DataReaderQos::type_consistency-api| | Yes |
+-----------------------------------------------+---------------------------------------------+----------+
| |datarepresentationqospolicy| | |DataReaderQos::representation-api| | Yes |
+-----------------------------------------------+---------------------------------------------+----------+
| |datasharingqospolicy| | |DataReaderQos::data_sharing-api| | No |
+-----------------------------------------------+---------------------------------------------+----------+
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -15,5 +15,4 @@ Subscriber
/fastdds/python_api_reference/dds_pim/subscriber/subscriber_class.rst
/fastdds/python_api_reference/dds_pim/subscriber/subscriberlistener.rst
/fastdds/python_api_reference/dds_pim/subscriber/subscriberqos.rst
/fastdds/python_api_reference/dds_pim/subscriber/typeconsistencyqos.rst
/fastdds/python_api_reference/dds_pim/subscriber/viewstatekind.rst

This file was deleted.

0 comments on commit 4119d79

Please sign in to comment.