/src/Fast-DDS/include/fastdds/dds/publisher/qos/WriterQos.hpp
Line | Count | Source (jump to first uncovered line) |
1 | | // Copyright 2016 Proyectos y Sistemas de Mantenimiento SL (eProsima). |
2 | | // |
3 | | // Licensed under the Apache License, Version 2.0 (the "License"); |
4 | | // you may not use this file except in compliance with the License. |
5 | | // You may obtain a copy of the License at |
6 | | // |
7 | | // http://www.apache.org/licenses/LICENSE-2.0 |
8 | | // |
9 | | // Unless required by applicable law or agreed to in writing, software |
10 | | // distributed under the License is distributed on an "AS IS" BASIS, |
11 | | // WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. |
12 | | // See the License for the specific language governing permissions and |
13 | | // limitations under the License. |
14 | | |
15 | | /** |
16 | | * @file WriterQos.hpp |
17 | | * |
18 | | */ |
19 | | |
20 | | #ifndef _FASTDDS_DDS_QOS_WRITERQOS_HPP_ |
21 | | #define _FASTDDS_DDS_QOS_WRITERQOS_HPP_ |
22 | | |
23 | | #include <fastdds/dds/core/policy/QosPolicies.hpp> |
24 | | |
25 | | namespace eprosima { |
26 | | namespace fastdds { |
27 | | namespace dds { |
28 | | |
29 | | /** |
30 | | * Class WriterQos, containing all the possible Qos that can be set for a determined Publisher. |
31 | | * Although these values can be set and are transmitted |
32 | | * during the Endpoint Discovery Protocol, not all of the behaviour associated with them has been implemented in the library. |
33 | | * Please consult each of them to check for implementation details and default values. |
34 | | * @ingroup FASTRTPS_ATTRIBUTES_MODULE |
35 | | */ |
36 | | class WriterQos |
37 | | { |
38 | | public: |
39 | | |
40 | | RTPS_DllAPI WriterQos(); |
41 | | RTPS_DllAPI virtual ~WriterQos(); |
42 | | |
43 | | bool operator ==( |
44 | | const WriterQos& b) const |
45 | 0 | { |
46 | 0 | return (this->m_durability == b.m_durability) && |
47 | 0 | (this->m_durabilityService == b.m_durabilityService) && |
48 | 0 | (this->m_deadline == b.m_deadline) && |
49 | 0 | (this->m_latencyBudget == b.m_latencyBudget) && |
50 | 0 | (this->m_liveliness == b.m_liveliness) && |
51 | 0 | (this->m_reliability == b.m_reliability) && |
52 | 0 | (this->m_lifespan == b.m_lifespan) && |
53 | 0 | (this->m_userData == b.m_userData) && |
54 | 0 | (this->m_timeBasedFilter == b.m_timeBasedFilter) && |
55 | 0 | (this->m_ownership == b.m_ownership) && |
56 | 0 | (this->m_ownershipStrength == b.m_ownershipStrength) && |
57 | 0 | (this->m_destinationOrder == b.m_destinationOrder) && |
58 | 0 | (this->m_presentation == b.m_presentation) && |
59 | 0 | (this->m_partition == b.m_partition) && |
60 | 0 | (this->m_topicData == b.m_topicData) && |
61 | 0 | (this->m_groupData == b.m_groupData) && |
62 | 0 | (this->m_publishMode == b.m_publishMode) && |
63 | 0 | (this->m_disablePositiveACKs == b.m_disablePositiveACKs) && |
64 | 0 | (this->representation == b.representation) && |
65 | 0 | (this->data_sharing == b.data_sharing); |
66 | 0 | } |
67 | | |
68 | | //!Durability Qos, implemented in the library. |
69 | | DurabilityQosPolicy m_durability; |
70 | | |
71 | | //!Durability Service Qos, NOT implemented in the library. |
72 | | DurabilityServiceQosPolicy m_durabilityService; |
73 | | |
74 | | //!Deadline Qos, implemented in the library. |
75 | | DeadlineQosPolicy m_deadline; |
76 | | |
77 | | //!Latency Budget Qos, NOT implemented in the library. |
78 | | LatencyBudgetQosPolicy m_latencyBudget; |
79 | | |
80 | | //!Liveliness Qos, implemented in the library. |
81 | | LivelinessQosPolicy m_liveliness; |
82 | | |
83 | | //!Reliability Qos, implemented in the library. |
84 | | ReliabilityQosPolicy m_reliability; |
85 | | |
86 | | //!Lifespan Qos, NOT implemented in the library. |
87 | | LifespanQosPolicy m_lifespan; |
88 | | |
89 | | //!UserData Qos, NOT implemented in the library. |
90 | | UserDataQosPolicy m_userData; |
91 | | |
92 | | //!Time Based Filter Qos, NOT implemented in the library. |
93 | | TimeBasedFilterQosPolicy m_timeBasedFilter; |
94 | | |
95 | | //!Ownership Qos, NOT implemented in the library. |
96 | | OwnershipQosPolicy m_ownership; |
97 | | |
98 | | //!Owenership Strength Qos, NOT implemented in the library. |
99 | | OwnershipStrengthQosPolicy m_ownershipStrength; |
100 | | |
101 | | //!Destination Order Qos, NOT implemented in the library. |
102 | | DestinationOrderQosPolicy m_destinationOrder; |
103 | | |
104 | | //!Presentation Qos, NOT implemented in the library. |
105 | | PresentationQosPolicy m_presentation; |
106 | | |
107 | | //!Partition Qos, implemented in the library. |
108 | | PartitionQosPolicy m_partition; |
109 | | |
110 | | //!Topic Data Qos, NOT implemented in the library. |
111 | | TopicDataQosPolicy m_topicData; |
112 | | |
113 | | //!Group Data Qos, NOT implemented in the library. |
114 | | GroupDataQosPolicy m_groupData; |
115 | | |
116 | | //!Publication Mode Qos, implemented in the library. |
117 | | PublishModeQosPolicy m_publishMode; |
118 | | |
119 | | //!Data Representation Qos, implemented in the library. |
120 | | DataRepresentationQosPolicy representation; |
121 | | |
122 | | //!Disable positive acks QoS, implemented in the library. |
123 | | DisablePositiveACKsQosPolicy m_disablePositiveACKs; |
124 | | |
125 | | //!Information for data sharing compatibility check. |
126 | | DataSharingQosPolicy data_sharing; |
127 | | |
128 | | //! Disable heartbeat piggyback mechanism. |
129 | | bool disable_heartbeat_piggyback = false; |
130 | | |
131 | | /** |
132 | | * Set Qos from another class |
133 | | * @param qos Reference from a WriterQos object. |
134 | | * @param first_time Boolean indicating whether is the first time (If not some parameters cannot be set). |
135 | | */ |
136 | | RTPS_DllAPI void setQos( |
137 | | const WriterQos& qos, |
138 | | bool first_time); |
139 | | |
140 | | /** |
141 | | * Check if the Qos values are compatible between each other. |
142 | | * @return True if correct. |
143 | | */ |
144 | | RTPS_DllAPI bool checkQos() const; |
145 | | |
146 | | RTPS_DllAPI bool canQosBeUpdated( |
147 | | const WriterQos& qos) const; |
148 | | |
149 | | void clear(); |
150 | | }; |
151 | | |
152 | | //RTPS_DllAPI extern const WriterQos DATAWRITER_QOS_DEFAULT; |
153 | | |
154 | | } //namespace dds |
155 | | } //namespace fastdds |
156 | | } //namespace eprosima |
157 | | |
158 | | #endif // _FASTDDS_DDS_QOS_WRITERQOS_HPP_ |