Fast DDS  Version 3.1.2
Fast DDS
Loading...
Searching...
No Matches
QosPolicies.hpp
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
20#ifndef FASTDDS_DDS_CORE_POLICY__QOSPOLICIES_HPP
21#define FASTDDS_DDS_CORE_POLICY__QOSPOLICIES_HPP
22
23#include <bitset>
24#include <vector>
25
26#include <fastdds/dds/core/policy/ParameterTypes.hpp>
27#include <fastdds/dds/core/Types.hpp>
28#include <fastdds/dds/xtypes/type_representation/detail/dds_xtypes_typeobject.hpp>
29#include <fastdds/rtps/attributes/ExternalLocators.hpp>
30#include <fastdds/rtps/attributes/PropertyPolicy.hpp>
31#include <fastdds/rtps/attributes/RTPSParticipantAllocationAttributes.hpp>
32#include <fastdds/rtps/attributes/RTPSParticipantAttributes.hpp>
33#include <fastdds/rtps/attributes/ThreadSettings.hpp>
34#include <fastdds/rtps/common/LocatorList.hpp>
35#include <fastdds/rtps/common/Time_t.hpp>
36#include <fastdds/rtps/common/Types.hpp>
37#include <fastdds/rtps/flowcontrol/FlowControllerConsts.hpp>
38#include <fastdds/rtps/attributes/ResourceManagement.hpp>
39#include <fastdds/rtps/transport/network/NetmaskFilterKind.hpp>
40
41#include <fastdds/utils/collections/ResourceLimitedVector.hpp>
42
43namespace eprosima {
44namespace fastdds {
45namespace dds {
46
54enum QosPolicyId_t : uint32_t
55{
56 INVALID_QOS_POLICY_ID = 0, //< Does not refer to any valid QosPolicy
57
58 // Standard QosPolicies
59 USERDATA_QOS_POLICY_ID = 1, //< UserDataQosPolicy
60 DURABILITY_QOS_POLICY_ID = 2, //< DurabilityQosPolicy
61 PRESENTATION_QOS_POLICY_ID = 3, //< PresentationQosPolicy
62 DEADLINE_QOS_POLICY_ID = 4, //< DeadlineQosPolicy
63 LATENCYBUDGET_QOS_POLICY_ID = 5, //< LatencyBudgetQosPolicy
64 OWNERSHIP_QOS_POLICY_ID = 6, //< OwnershipQosPolicy
65 OWNERSHIPSTRENGTH_QOS_POLICY_ID = 7, //< OwnershipStrengthQosPolicy
66 LIVELINESS_QOS_POLICY_ID = 8, //< LivelinessQosPolicy
67 TIMEBASEDFILTER_QOS_POLICY_ID = 9, //< TimeBasedFilterQosPolicy
68 PARTITION_QOS_POLICY_ID = 10, //< PartitionQosPolicy
69 RELIABILITY_QOS_POLICY_ID = 11, //< ReliabilityQosPolicy
70 DESTINATIONORDER_QOS_POLICY_ID = 12, //< DestinationOrderQosPolicy
71 HISTORY_QOS_POLICY_ID = 13, //< HistoryQosPolicy
72 RESOURCELIMITS_QOS_POLICY_ID = 14, //< ResourceLimitsQosPolicy
73 ENTITYFACTORY_QOS_POLICY_ID = 15, //< EntityFactoryQosPolicy
74 WRITERDATALIFECYCLE_QOS_POLICY_ID = 16, //< WriterDataLifecycleQosPolicy
75 READERDATALIFECYCLE_QOS_POLICY_ID = 17, //< ReaderDataLifecycleQosPolicy
76 TOPICDATA_QOS_POLICY_ID = 18, //< TopicDataQosPolicy
77 GROUPDATA_QOS_POLICY_ID = 19, //< GroupDataQosPolicy
78 TRANSPORTPRIORITY_QOS_POLICY_ID = 20, //< TransportPriorityQosPolicy
79 LIFESPAN_QOS_POLICY_ID = 21, //< LifespanQosPolicy
80 DURABILITYSERVICE_QOS_POLICY_ID = 22, //< DurabilityServiceQosPolicy
81
82 //XTypes extensions
83 DATAREPRESENTATION_QOS_POLICY_ID = 23, //< DataRepresentationQosPolicy
84 TYPECONSISTENCYENFORCEMENT_QOS_POLICY_ID = 24, //< TypeConsistencyEnforcementQosPolicy
85
86 //eProsima Extensions
87 DISABLEPOSITIVEACKS_QOS_POLICY_ID = 25, //< DisablePositiveACKsQosPolicy
88 PARTICIPANTRESOURCELIMITS_QOS_POLICY_ID = 26, //< ParticipantResourceLimitsQos
89 PROPERTYPOLICY_QOS_POLICY_ID = 27, //< PropertyPolicyQos
90 PUBLISHMODE_QOS_POLICY_ID = 28, //< PublishModeQosPolicy
91 READERRESOURCELIMITS_QOS_POLICY_ID = 29, //< Reader ResourceLimitsQos
92 RTPSENDPOINT_QOS_POLICY_ID = 30, //< RTPSEndpointQos
93 RTPSRELIABLEREADER_QOS_POLICY_ID = 31, //< RTPSReliableReaderQos
94 RTPSRELIABLEWRITER_QOS_POLICY_ID = 32, //< RTPSReliableWriterQos
95 TRANSPORTCONFIG_QOS_POLICY_ID = 33, //< TransportConfigQos
96 TYPECONSISTENCY_QOS_POLICY_ID = 34, //< TipeConsistencyQos
97 WIREPROTOCOLCONFIG_QOS_POLICY_ID = 35, //< WireProtocolConfigQos
98 WRITERRESOURCELIMITS_QOS_POLICY_ID = 36, //< WriterResourceLimitsQos
99
100 NEXT_QOS_POLICY_ID //< Keep always the last element. For internal use only
102
103using PolicyMask = std::bitset<NEXT_QOS_POLICY_ID>;
104
109{
110public:
111
114
119 : hasChanged(false)
120 , send_always_(false)
121 {
122 }
123
129 explicit QosPolicy(
130 bool send_always)
131 : hasChanged(false)
133 {
134 }
135
142 const QosPolicy& b) = default;
143
147 virtual ~QosPolicy() = default;
148
150 const QosPolicy& b) const
151 {
152 // hasChanged field isn't needed to be compared to being equal two QosPolicy objects.
153 return (this->send_always_ == b.send_always_);
154 }
155
157 const QosPolicy& b) = default;
158
164 virtual bool send_always() const
165 {
166 return send_always_;
167 }
168
172 virtual inline void clear() = 0;
173
174protected:
175
178};
179
187{
188public:
189
196
200 FASTDDS_EXPORTED_API EntityFactoryQosPolicy()
202 {
203 }
204
210 FASTDDS_EXPORTED_API EntityFactoryQosPolicy(
211 bool autoenable)
212 : autoenable_created_entities(autoenable)
213 {
214 }
215
219 virtual FASTDDS_EXPORTED_API ~EntityFactoryQosPolicy()
220 {
221 }
222
224 const EntityFactoryQosPolicy& b) const
225 {
226 return
227 (this->autoenable_created_entities == b.autoenable_created_entities);
228 }
229
230 inline void clear()
231 {
233 std::swap(*this, reset);
234 }
235
236};
237
266
267#define PARAMETER_KIND_LENGTH 4
268#define PARAMETER_BOOL_LENGTH 4
269
276{
277public:
278
282 FASTDDS_EXPORTED_API DurabilityQosPolicy()
283 : Parameter_t(PID_DURABILITY, PARAMETER_KIND_LENGTH)
284 , QosPolicy(true)
286 {
287 }
288
292 virtual FASTDDS_EXPORTED_API ~DurabilityQosPolicy() = default;
293
310
312 const DurabilityQosPolicy& b) const
313 {
314 return (this->kind == b.kind) &&
317 }
318
324 inline void durabilityKind(
325 const fastdds::rtps::DurabilityKind_t new_kind)
326 {
327 switch (new_kind)
328 {
329 default:
334 }
335
336 }
337
338 inline void clear() override
339 {
341 std::swap(*this, reset);
342 }
343
344public:
345
351};
352
361{
362public:
363
367 FASTDDS_EXPORTED_API DeadlineQosPolicy()
369 , QosPolicy(true)
370 , period(TIME_T_INFINITE_SECONDS, TIME_T_INFINITE_NANOSECONDS)
371 {
372 }
373
377 virtual FASTDDS_EXPORTED_API ~DeadlineQosPolicy() = default;
378
380 const DeadlineQosPolicy& b) const
381 {
382 return (this->period == b.period) &&
385 }
386
387 inline void clear() override
388 {
390 std::swap(*this, reset);
391 }
392
393public:
394
402};
403
414{
415public:
416
420 FASTDDS_EXPORTED_API LatencyBudgetQosPolicy()
422 , QosPolicy(true)
423 , duration(0, 0)
424 {
425 }
426
430 virtual FASTDDS_EXPORTED_API ~LatencyBudgetQosPolicy() = default;
431
433 const LatencyBudgetQosPolicy& b) const
434 {
435 return (this->duration == b.duration) &&
438 }
439
440 inline void clear() override
441 {
443 std::swap(*this, reset);
444 }
445
446public:
447
450};
451
472
486{
487public:
488
492 FASTDDS_EXPORTED_API LivelinessQosPolicy()
493 : Parameter_t(PID_LIVELINESS, PARAMETER_KIND_LENGTH + PARAMETER_TIME_LENGTH)
494 , QosPolicy(true)
496 , lease_duration(TIME_T_INFINITE_SECONDS, TIME_T_INFINITE_NANOSECONDS)
497 , announcement_period(TIME_T_INFINITE_SECONDS, TIME_T_INFINITE_NANOSECONDS)
498 {
499 }
500
504 virtual FASTDDS_EXPORTED_API ~LivelinessQosPolicy() = default;
505
507 const LivelinessQosPolicy& b) const
508 {
509 return (this->kind == b.kind) &&
510 (this->lease_duration == b.lease_duration) &&
514 }
515
516 inline void clear() override
517 {
519 std::swap(*this, reset);
520 }
521
522public:
523
540};
541
561
568{
569public:
570
574 FASTDDS_EXPORTED_API ReliabilityQosPolicy()
575 : Parameter_t(PID_RELIABILITY, PARAMETER_KIND_LENGTH + PARAMETER_TIME_LENGTH)
576 , QosPolicy(true) //indicate send always
578 , max_blocking_time{0, 100000000} // max_blocking_time = 100ms
579 {
580 }
581
585 virtual FASTDDS_EXPORTED_API ~ReliabilityQosPolicy() = default;
586
588 const ReliabilityQosPolicy& b) const
589 {
590 return (this->kind == b.kind) &&
592 Parameter_t::operator ==(b) &&
594 }
595
596 inline void clear() override
597 {
599 std::swap(*this, reset);
600 }
601
602public:
603
609
621};
622
623
624
642
650{
651public:
652
656 FASTDDS_EXPORTED_API OwnershipQosPolicy()
657 : Parameter_t(PID_OWNERSHIP, PARAMETER_KIND_LENGTH)
658 , QosPolicy(true)
660 {
661 }
662
666 virtual FASTDDS_EXPORTED_API ~OwnershipQosPolicy() = default;
667
669 const OwnershipQosPolicy& b) const
670 {
671 return (this->kind == b.kind) &&
674 }
675
676 inline void clear() override
677 {
679 std::swap(*this, reset);
680 }
681
682public:
683
686};
687
705
706
707
717{
718public:
719
723 FASTDDS_EXPORTED_API DestinationOrderQosPolicy()
724 : Parameter_t(PID_DESTINATION_ORDER, PARAMETER_KIND_LENGTH)
725 , QosPolicy(true)
727 {
728 }
729
733 virtual FASTDDS_EXPORTED_API ~DestinationOrderQosPolicy() = default;
734
736 const DestinationOrderQosPolicy& b) const
737 {
738 return (this->kind == b.kind) &&
741 }
742
743 inline void clear() override
744 {
746 std::swap(*this, reset);
747 }
748
749public:
750
753};
754
755
760 public fastdds::ResourceLimitedVector<fastdds::rtps::octet>
761{
763
764public:
765
766 FASTDDS_EXPORTED_API GenericDataQosPolicy(
767 ParameterId_t pid)
768 : Parameter_t(pid, 0)
769 , QosPolicy(false)
771 {
772 }
773
774 FASTDDS_EXPORTED_API GenericDataQosPolicy(
775 ParameterId_t pid,
776 uint16_t in_length)
777 : Parameter_t(pid, in_length)
778 , QosPolicy(false)
780 {
781 }
782
791 FASTDDS_EXPORTED_API GenericDataQosPolicy(
794 , QosPolicy(false)
796 {
797 }
798
808 FASTDDS_EXPORTED_API GenericDataQosPolicy(
809 ParameterId_t pid,
810 const collection_type& data)
811 : Parameter_t(pid, 0)
812 , QosPolicy(false)
814 {
815 assign(data.begin(), data.end());
816 length = static_cast<uint16_t>((size() + 7u) & ~3u);
817 }
818
819 virtual FASTDDS_EXPORTED_API ~GenericDataQosPolicy() = default;
820
833 const collection_type& b)
834 {
835 if (collection_ != b)
836 {
837 //If the object is size limited, already has max_size() allocated
838 //assign() will always stop copying when reaching max_size()
839 assign(b.begin(), b.end());
840 length = static_cast<uint16_t>((size() + 7u) & ~3u);
841 hasChanged = true;
842 }
843 return *this;
844 }
845
856 const GenericDataQosPolicy& b)
857 {
859 Parameter_t::operator =(b);
861 collection_.reserve(b.collection_.capacity());
862 collection_.assign(b.collection_.begin(), b.collection_.end());
863 return *this;
864 }
865
867 const GenericDataQosPolicy& b) const
868 {
869 return collection_ == b.collection_ &&
872 }
873
875 const collection_type& b) const
876 {
877 return collection_ == b;
878 }
879
898
899 void resize(
900 size_t new_size)
901 {
902 collection_.resize(new_size);
903 }
904
908 inline const collection_type& dataVec() const
909 {
910 return collection_;
911 }
912
913 inline void clear() override
914 {
916 hasChanged = false;
917 }
918
924 FASTDDS_EXPORTED_API inline const collection_type& data_vec() const
925 {
926 return collection_;
927 }
928
934 FASTDDS_EXPORTED_API inline collection_type& data_vec()
935 {
936 return collection_;
937 }
938
944 FASTDDS_EXPORTED_API inline void data_vec(
945 const collection_type& vec)
946 {
947 if (collection_ != vec)
948 {
949 assign(vec.begin(), vec.end());
950 length = static_cast<uint16_t>((size() + 7u) & ~3u);
951 hasChanged = true;
952 }
953 }
954
960 FASTDDS_EXPORTED_API inline const collection_type& getValue() const
961 {
962 return collection_;
963 }
964
970 FASTDDS_EXPORTED_API inline void setValue(
971 const collection_type& vec)
972 {
973 data_vec(vec);
974 }
975
976};
977
985// *INDENT-OFF* (uncrustify seems to have problems with this macro)
986#define TEMPLATE_DATA_QOS_POLICY(TClassName, TPid) \
987 class TClassName : public GenericDataQosPolicy \
988 { \
989 public: \
990 \
991 FASTDDS_EXPORTED_API TClassName() \
992 : GenericDataQosPolicy(TPid) \
993 { \
994 } \
995 \
996 FASTDDS_EXPORTED_API TClassName( \
997 uint16_t in_length) \
998 : GenericDataQosPolicy(TPid, in_length) \
999 { \
1000 } \
1001 \
1002 \
1010 FASTDDS_EXPORTED_API TClassName( \
1011 const TClassName &data) = default; \
1012 \
1013 \
1021 FASTDDS_EXPORTED_API TClassName( \
1022 const collection_type &data) \
1023 : GenericDataQosPolicy(TPid, data) \
1024 { \
1025 } \
1026 \
1027 virtual FASTDDS_EXPORTED_API ~TClassName() = default; \
1028 \
1029 \
1038 TClassName& operator =( \
1039 const TClassName& b) = default; \
1040 };
1041// *INDENT-ON*
1042
1043//Variable used to generate the doxygen documentation for this QoS Policies
1044#ifdef DOXYGEN_DOCUMENTATION
1055class UserDataQosPolicy : public GenericDataQosPolicy
1056{
1057};
1068class TopicDataQosPolicy : public GenericDataQosPolicy
1069{
1070};
1082class GroupDataQosPolicy : public GenericDataQosPolicy
1083{
1084};
1085#endif // DOXYGEN_DOCUMENTATION
1087TEMPLATE_DATA_QOS_POLICY(UserDataQosPolicy, PID_USER_DATA)
1088TEMPLATE_DATA_QOS_POLICY(TopicDataQosPolicy, PID_TOPIC_DATA)
1089TEMPLATE_DATA_QOS_POLICY(GroupDataQosPolicy, PID_GROUP_DATA)
1090
1091
1101class TimeBasedFilterQosPolicy : public Parameter_t, public QosPolicy
1102{
1103public:
1104
1108 FASTDDS_EXPORTED_API TimeBasedFilterQosPolicy()
1110 , QosPolicy(false)
1111 , minimum_separation(0, 0)
1112 {
1113 }
1114
1118 virtual FASTDDS_EXPORTED_API ~TimeBasedFilterQosPolicy() = default;
1119
1120 bool operator ==(
1122 {
1123 return (this->minimum_separation == b.minimum_separation) &&
1126 }
1127
1128 inline void clear() override
1129 {
1131 std::swap(*this, reset);
1132 }
1134public:
1135
1139
1144{
1161
1162#define PARAMETER_PRESENTATION_LENGTH 8
1163
1175class PresentationQosPolicy : public Parameter_t, public QosPolicy
1176{
1177public:
1178
1182 FASTDDS_EXPORTED_API PresentationQosPolicy()
1183 : Parameter_t(PID_PRESENTATION, PARAMETER_PRESENTATION_LENGTH)
1184 , QosPolicy(false)
1186 , coherent_access(false)
1187 , ordered_access(false)
1188 {
1189 }
1190
1194 virtual FASTDDS_EXPORTED_API ~PresentationQosPolicy() = default;
1195
1196 bool operator ==(
1197 const PresentationQosPolicy& b) const
1198 {
1199 return (this->access_scope == b.access_scope) &&
1200 (this->coherent_access == b.coherent_access) &&
1201 (this->ordered_access == b.ordered_access) &&
1204 }
1206 inline void clear() override
1207 {
1209 std::swap(*this, reset);
1210 }
1211
1212public:
1213
1221 bool coherent_access;
1227 bool ordered_access;
1228};
1229
1230
1231class Partition_t
1233
1234 friend class PartitionQosPolicy;
1235
1236private:
1237
1238 const char* partition_;
1239
1240private:
1241
1242 Partition_t()
1243 {
1244 partition_ = nullptr;
1246
1247public:
1248
1254 explicit Partition_t(
1255 const void* ptr)
1257 partition_ = (char*)ptr;
1258 }
1259
1260 bool operator ==(
1261 const Partition_t& rhs) const
1262 {
1263 return (size() == rhs.size() &&
1264 (size() == 0 || strcmp(partition_ + 4, rhs.partition_ + 4)));
1265 }
1267 bool operator !=(
1268 const Partition_t& rhs) const
1269 {
1270 return !(*this == rhs);
1271 }
1272
1278 uint32_t size() const
1279 {
1280 return *(uint32_t*)partition_;
1281 }
1282
1288 const char* name() const
1289 {
1290 return partition_ + 4;
1305class PartitionQosPolicy : public Parameter_t, public QosPolicy
1306{
1307public:
1308
1309 class const_iterator
1311 public:
1312
1313 typedef const_iterator self_type;
1314 typedef const Partition_t value_type;
1315 typedef const Partition_t reference;
1316 typedef const Partition_t* pointer;
1317 typedef size_t difference_type;
1318 typedef std::forward_iterator_tag iterator_category;
1319
1326 const fastdds::rtps::octet* ptr)
1327 : ptr_(ptr)
1328 , value_ (ptr_)
1330 }
1331
1333 {
1334 self_type tmp = *this;
1335 advance();
1336 return tmp;
1337 }
1338
1340 int)
1341 {
1342 advance();
1343 return *this;
1344 }
1345
1347 {
1348 return value_;
1349 }
1350
1352 {
1353 return &value_;
1354 }
1355
1356 bool operator ==(
1357 const self_type& rhs) const
1358 {
1359 return ptr_ == rhs.ptr_;
1360 }
1361
1362 bool operator !=(
1363 const self_type& rhs) const
1364 {
1365 return ptr_ != rhs.ptr_;
1366 }
1367
1368 protected:
1369
1373 void advance()
1374 {
1375 //Size of the element (with alignment)
1376 uint32_t size = *(uint32_t*)ptr_;
1377 ptr_ += (4u + ((size + 3u) & ~3u));
1378 value_ = Partition_t(ptr_);
1379 }
1380
1381 private:
1382
1384 const fastdds::rtps::octet* ptr_;
1387
1388 };
1389
1390public:
1391
1395 FASTDDS_EXPORTED_API PartitionQosPolicy()
1397 , QosPolicy(false)
1398 , max_size_ (0)
1399 , Npartitions_ (0)
1400 {
1402
1408 FASTDDS_EXPORTED_API PartitionQosPolicy(
1409 uint16_t in_length)
1410 : Parameter_t(PID_PARTITION, in_length)
1411 , QosPolicy(false)
1412 , max_size_ (in_length)
1413 , partitions_(in_length)
1414 , Npartitions_ (0)
1415 {
1416 }
1423 FASTDDS_EXPORTED_API PartitionQosPolicy(
1424 const PartitionQosPolicy& b)
1425 : Parameter_t(b)
1426 , QosPolicy(b)
1427 , max_size_ (b.max_size_)
1428 , partitions_(b.max_size_ != 0 ?
1429 b.partitions_.max_size :
1430 b.partitions_.length)
1431 , Npartitions_ (b.Npartitions_)
1432 {
1433 partitions_.copy(&b.partitions_, b.max_size_ != 0);
1434 }
1435
1439 virtual FASTDDS_EXPORTED_API ~PartitionQosPolicy() = default;
1440
1441 bool operator ==(
1442 const PartitionQosPolicy& b) const
1443 {
1444 return (this->max_size_ == b.max_size_) &&
1445 (this->Npartitions_ == b.Npartitions_) &&
1446 (this->partitions_ == b.partitions_) &&
1453 {
1455 Parameter_t::operator =(b);
1456 max_size_ = b.max_size_;
1457 partitions_.reserve(max_size_ != 0 ?
1458 b.partitions_.max_size :
1459 b.partitions_.length);
1460 partitions_.copy(&b.partitions_, b.max_size_ != 0);
1461 Npartitions_ = b.Npartitions_;
1462
1463 return *this;
1464 }
1465
1471 const_iterator begin() const
1472 {
1473 return const_iterator(partitions_.data);
1474 }
1475
1481 const_iterator end() const
1482 {
1483 return const_iterator(partitions_.data + partitions_.length);
1484 }
1485
1491 uint32_t size() const
1492 {
1493 return Npartitions_;
1494 }
1495
1501 uint32_t empty() const
1502 {
1503 return Npartitions_ == 0;
1504 }
1505
1512 uint32_t size)
1513 {
1514 partitions_.reserve(size);
1515 max_size_ = size;
1516 }
1517
1523 uint32_t max_size () const
1524 {
1525 return max_size_;
1526 }
1527
1533 FASTDDS_EXPORTED_API inline void push_back(
1534 const char* name)
1535 {
1536 //Realloc if needed;
1537 uint32_t size = (uint32_t)strlen(name) + 1;
1538 uint32_t alignment = ((size + 3u) & ~3u) - size;
1539
1540 if (max_size_ != 0 && (partitions_.max_size < partitions_.length +
1541 size + alignment + 4))
1542 {
1543 return;
1544 }
1545
1546 partitions_.reserve(partitions_.length + size + alignment + 4);
1547
1549 memcpy(partitions_.data + partitions_.length, o, 4);
1550 partitions_.length += 4;
1551
1552 memcpy(partitions_.data + partitions_.length, name, size);
1553 partitions_.length += size;
1554
1555 memset(partitions_.data + partitions_.length, 0, alignment);
1556 partitions_.length += alignment;
1557
1558 ++Npartitions_;
1559 hasChanged = true;
1560 }
1561
1565 FASTDDS_EXPORTED_API inline void clear() override
1566 {
1567 partitions_.length = 0;
1568 Npartitions_ = 0;
1569 hasChanged = false;
1570 }
1571
1577 FASTDDS_EXPORTED_API inline const std::vector<std::string> getNames() const
1578 {
1579 return names();
1580 }
1581
1587 FASTDDS_EXPORTED_API inline void setNames(
1588 std::vector<std::string>& nam)
1589 {
1590 names(nam);
1591 }
1592
1598 FASTDDS_EXPORTED_API inline const std::vector<std::string> names() const
1599 {
1600 std::vector<std::string> names;
1601 if (Npartitions_ > 0)
1602 {
1603 for (auto it = begin(); it != end(); ++it)
1604 {
1605 names.push_back(it->name());
1606 }
1607 }
1608 return names;
1609 }
1610
1616 FASTDDS_EXPORTED_API inline void names(
1617 std::vector<std::string>& nam)
1619 clear();
1620 for (auto it = nam.begin(); it != nam.end(); ++it)
1621 {
1622 push_back(it->c_str());
1623 }
1624 hasChanged = true;
1625 }
1627private:
1628
1630 uint32_t max_size_;
1634 uint32_t Npartitions_;
1636
1641{
1657};
1658
1670class HistoryQosPolicy : public Parameter_t, public QosPolicy
1671{
1672public:
1673
1677 FASTDDS_EXPORTED_API HistoryQosPolicy()
1678 : Parameter_t(PID_HISTORY, PARAMETER_KIND_LENGTH + 4)
1679 , QosPolicy(true)
1681 , depth(1)
1682 {
1683 }
1684
1688 virtual FASTDDS_EXPORTED_API ~HistoryQosPolicy() = default;
1689
1690 bool operator ==(
1691 const HistoryQosPolicy& b) const
1693 return (this->kind == b.kind) &&
1694 (this->depth == b.depth) &&
1695 Parameter_t::operator ==(b) &&
1697 }
1698
1699 inline void clear() override
1702 std::swap(*this, reset);
1703 }
1704
1705public:
1706
1714 int32_t depth;
1715};
1716
1722class ResourceLimitsQosPolicy : public Parameter_t, public QosPolicy
1723{
1724public:
1725
1734 int32_t max_samples;
1753 int32_t allocated_samples;
1758 int32_t extra_samples;
1759
1763 FASTDDS_EXPORTED_API ResourceLimitsQosPolicy()
1764 : Parameter_t(PID_RESOURCE_LIMITS, 4 + 4 + 4)
1765 , QosPolicy(false)
1766 , max_samples(5000)
1767 , max_instances(10)
1769 , allocated_samples(100)
1770 , extra_samples(1)
1771 {
1772 }
1773
1777 virtual FASTDDS_EXPORTED_API ~ResourceLimitsQosPolicy() = default;
1778
1779 bool operator ==(
1780 const ResourceLimitsQosPolicy& b) const
1781 {
1782 return (this->max_samples == b.max_samples) &&
1783 (this->max_instances == b.max_instances) &&
1784 (this->max_samples_per_instance == b.max_samples_per_instance) &&
1785 (this->allocated_samples == b.allocated_samples) &&
1786 Parameter_t::operator ==(b) &&
1788 }
1789
1790 inline void clear() override
1791 {
1793 std::swap(*this, reset);
1794 }
1795
1796};
1797
1798
1799
1808class DurabilityServiceQosPolicy : public Parameter_t, public QosPolicy
1810public:
1811
1815 FASTDDS_EXPORTED_API DurabilityServiceQosPolicy()
1816 : Parameter_t(PID_DURABILITY_SERVICE, PARAMETER_TIME_LENGTH + PARAMETER_KIND_LENGTH + 4 + 4 + 4 + 4)
1817 , QosPolicy(false)
1819 , history_depth(1)
1829 virtual FASTDDS_EXPORTED_API ~DurabilityServiceQosPolicy() = default;
1830
1831 bool operator ==(
1832 const DurabilityServiceQosPolicy& b) const
1834 return (this->history_kind == b.history_kind) &&
1835 (this->history_depth == b.history_depth) &&
1836 (this->max_samples == b.max_samples) &&
1837 (this->max_instances == b.max_instances) &&
1838 (this->max_samples_per_instance == b.max_samples_per_instance) &&
1841 }
1842
1843 inline void clear() override
1844 {
1846 std::swap(*this, reset);
1847 }
1848
1849public:
1850
1867 int32_t history_depth;
1875 int32_t max_samples;
1889};
1890
1896class LifespanQosPolicy : public Parameter_t, public QosPolicy
1897{
1898public:
1899
1903 FASTDDS_EXPORTED_API LifespanQosPolicy()
1905 , QosPolicy(true)
1906 , duration(TIME_T_INFINITE_SECONDS, TIME_T_INFINITE_NANOSECONDS)
1907 {
1908 }
1909
1913 virtual FASTDDS_EXPORTED_API ~LifespanQosPolicy() = default;
1914
1915 bool operator ==(
1916 const LifespanQosPolicy& b) const
1917 {
1918 return (this->duration == b.duration) &&
1921 }
1922
1923 inline void clear() override
1924 {
1926 std::swap(*this, reset);
1928
1929public:
1930
1933};
1934
1942class OwnershipStrengthQosPolicy : public Parameter_t, public QosPolicy
1943{
1944public:
1945
1949 FASTDDS_EXPORTED_API OwnershipStrengthQosPolicy()
1951 , QosPolicy(false)
1952 , value(0)
1953 {
1954 }
1955
1959 virtual FASTDDS_EXPORTED_API ~OwnershipStrengthQosPolicy() = default;
1960
1961 bool operator ==(
1962 const OwnershipStrengthQosPolicy& b) const
1963 {
1964 return (this->value == b.value) &&
1968
1969 inline void clear() override
1970 {
1972 std::swap(*this, reset);
1973 }
1974
1975public:
1976
1978 uint32_t value;
1979};
1980
1981
1990{
1991public:
1992
1994 uint32_t value;
1995
1999 FASTDDS_EXPORTED_API TransportPriorityQosPolicy()
2001 , QosPolicy(false)
2002 , value(0)
2003 {
2004 }
2005
2009 virtual FASTDDS_EXPORTED_API ~TransportPriorityQosPolicy() = default;
2011 bool operator ==(
2013 {
2014 return (this->value == b.value) &&
2018
2019 inline void clear() override
2020 {
2022 std::swap(*this, reset);
2023 }
2024
2025};
2026
2035
2039class PublishModeQosPolicy : public QosPolicy
2040{
2041public:
2042
2045
2052 inline void clear() override
2053 {
2055 std::swap(*this, reset);
2056 }
2058 bool operator ==(
2059 const PublishModeQosPolicy& b) const
2060 {
2061 return (this->kind == b.kind) &&
2064 }
2065
2066};
2067
2071typedef enum DataRepresentationId : int16_t
2072{
2077
2079constexpr DataRepresentationId_t DEFAULT_DATA_REPRESENTATION {DataRepresentationId_t::XCDR_DATA_REPRESENTATION};
2080
2092{
2093public:
2094
2096 std::vector<DataRepresentationId_t> m_value;
2097
2101 FASTDDS_EXPORTED_API DataRepresentationQosPolicy()
2103 , QosPolicy(false)
2105 }
2106
2110 virtual FASTDDS_EXPORTED_API ~DataRepresentationQosPolicy() override = default;
2111
2118 bool operator ==(
2119 const DataRepresentationQosPolicy& b) const
2120 {
2121 return (this->m_value == b.m_value) &&
2124 }
2125
2126 inline void clear() override
2127 {
2129 std::swap(*this, reset);
2130 }
2132};
2133
2134enum TypeConsistencyKind : uint16_t
2135{
2146
2155public:
2156
2196
2200 FASTDDS_EXPORTED_API TypeConsistencyEnforcementQosPolicy()
2201 : Parameter_t(PID_TYPE_CONSISTENCY_ENFORCEMENT, 8) // 2 + 5 + 1 alignment byte
2202 , QosPolicy(true)
2203 {
2207 m_ignore_member_names = false;
2210 }
2211
2215 virtual FASTDDS_EXPORTED_API ~TypeConsistencyEnforcementQosPolicy() override = default;
2216
2217 bool operator ==(
2219 {
2220 return m_kind == b.m_kind &&
2229
2230 inline void clear() override
2231 {
2233 std::swap(*this, reset);
2234 }
2235
2236};
2237
2243class DisablePositiveACKsQosPolicy : public Parameter_t, public QosPolicy
2244{
2245public:
2246
2250 FASTDDS_EXPORTED_API DisablePositiveACKsQosPolicy()
2252 , QosPolicy(true)
2253 , enabled(false)
2254 , duration(TIME_T_INFINITE_SECONDS, TIME_T_INFINITE_NANOSECONDS)
2255 {
2256 }
2257
2261 virtual FASTDDS_EXPORTED_API ~DisablePositiveACKsQosPolicy() = default;
2262
2263 bool operator ==(
2264 const DisablePositiveACKsQosPolicy& b) const
2265 {
2266 return enabled == b.enabled &&
2267 duration == b.duration &&
2270 }
2271
2272 inline void clear() override
2273 {
2275 std::swap(*this, reset);
2276 }
2277
2278public:
2279
2281 bool enabled;
2284};
2285
2289class TypeIdV1 : public Parameter_t, public QosPolicy
2291public:
2292
2295
2296
2300 FASTDDS_EXPORTED_API TypeIdV1()
2302 , QosPolicy(false)
2304 {
2305 }
2306
2312 FASTDDS_EXPORTED_API TypeIdV1(
2313 const TypeIdV1& type)
2314 : Parameter_t(type.Pid, type.length)
2315 , QosPolicy(type.send_always_)
2317 {
2318 }
2319
2325 FASTDDS_EXPORTED_API TypeIdV1(
2326 const xtypes::TypeIdentifier& identifier)
2328 , QosPolicy(false)
2329 , m_type_identifier(identifier)
2330 {
2331 }
2332
2338 FASTDDS_EXPORTED_API TypeIdV1(
2339 TypeIdV1&& type)
2340 : Parameter_t(type.Pid, type.length)
2341 , QosPolicy(type.send_always_)
2343 {
2344 }
2345
2346 FASTDDS_EXPORTED_API TypeIdV1& operator =(
2347 const TypeIdV1& type)
2348 {
2349 Pid = type.Pid;
2350 length = type.length;
2351 send_always_ = type.send_always_;
2352
2353 m_type_identifier = type.m_type_identifier;
2354
2355 return *this;
2356 }
2357
2358 FASTDDS_EXPORTED_API TypeIdV1& operator =(
2359 TypeIdV1&& type)
2360 {
2361 Pid = type.Pid;
2362 length = type.length;
2363 send_always_ = type.send_always_;
2364
2365 m_type_identifier = std::move(type.m_type_identifier);
2366
2367 return *this;
2368 }
2369
2373 virtual FASTDDS_EXPORTED_API ~TypeIdV1() override = default;
2374
2375 inline void clear() override
2376 {
2377 *this = TypeIdV1();
2378 }
2379
2380 FASTDDS_EXPORTED_API TypeIdV1& operator =(
2381 const xtypes::TypeIdentifier& type_id)
2382 {
2383 m_type_identifier = type_id;
2384 return *this;
2386
2392 FASTDDS_EXPORTED_API const xtypes::TypeIdentifier& get() const
2393 {
2394 return m_type_identifier;
2395 }
2396
2397};
2398
2402class TypeObjectV1 : public Parameter_t, public QosPolicy
2403{
2404public:
2405
2408
2412 FASTDDS_EXPORTED_API TypeObjectV1()
2414 , QosPolicy(false)
2416 {
2417 }
2418
2424 FASTDDS_EXPORTED_API TypeObjectV1(
2425 const TypeObjectV1& type)
2426 : Parameter_t(type.Pid, type.length)
2427 , QosPolicy(type.send_always_)
2429 {
2430 }
2431
2437 FASTDDS_EXPORTED_API TypeObjectV1(
2438 const xtypes::TypeObject& type)
2440 , QosPolicy(false)
2441 , m_type_object(type)
2442 {
2443 }
2444
2450 FASTDDS_EXPORTED_API TypeObjectV1(
2451 TypeObjectV1&& type)
2452 : Parameter_t(type.Pid, type.length)
2453 , QosPolicy(type.send_always_)
2454 , m_type_object(std::move(type.m_type_object))
2455 {
2456 }
2457
2458 FASTDDS_EXPORTED_API TypeObjectV1& operator =(
2459 const TypeObjectV1& type)
2460 {
2461 Pid = type.Pid;
2462 length = type.length;
2463 send_always_ = type.send_always_;
2464
2465 m_type_object = type.m_type_object;
2466
2467 return *this;
2468 }
2469
2470 FASTDDS_EXPORTED_API TypeObjectV1& operator =(
2471 TypeObjectV1&& type)
2472 {
2473 Pid = type.Pid;
2474 length = type.length;
2475 send_always_ = type.send_always_;
2476
2477 m_type_object = std::move(type.m_type_object);
2478
2479 return *this;
2480 }
2481
2485 virtual FASTDDS_EXPORTED_API ~TypeObjectV1() override = default;
2486
2487 inline void clear() override
2488 {
2489 *this = TypeObjectV1();
2490 }
2491
2492 FASTDDS_EXPORTED_API TypeObjectV1& operator =(
2493 const xtypes::TypeObject& type_object)
2495 m_type_object = type_object;
2496 return *this;
2497 }
2498
2504 FASTDDS_EXPORTED_API const xtypes::TypeObject& get() const
2505 {
2506 return m_type_object;
2507 }
2508
2509};
2510
2511namespace xtypes {
2512
2516class TypeInformationParameter : public Parameter_t, public QosPolicy
2526 FASTDDS_EXPORTED_API TypeInformationParameter()
2528 , QosPolicy(false)
2530 , assigned_(false)
2532 }
2533
2539 FASTDDS_EXPORTED_API TypeInformationParameter(
2540 const TypeInformationParameter& type)
2541 : Parameter_t(type.Pid, type.length)
2542 , QosPolicy(type.send_always_)
2544 , assigned_(type.assigned_)
2546 }
2547
2553 FASTDDS_EXPORTED_API TypeInformationParameter(
2556 , QosPolicy(false)
2557 , type_information(info)
2558 , assigned_(true)
2559 {
2560 }
2561
2567 FASTDDS_EXPORTED_API TypeInformationParameter(
2569 : Parameter_t(type.Pid, type.length)
2570 , QosPolicy(type.send_always_)
2572 , assigned_(type.assigned_)
2573 {
2574 }
2575
2576 FASTDDS_EXPORTED_API TypeInformationParameter& operator =(
2577 const TypeInformationParameter& type)
2578 {
2579 Pid = type.Pid;
2580 length = type.length;
2582
2584 assigned_ = type.assigned_;
2586 return *this;
2587 }
2588
2589 FASTDDS_EXPORTED_API TypeInformationParameter& operator =(
2591 {
2592 Pid = type.Pid;
2593 length = type.length;
2594 send_always_ = type.send_always_;
2596 type_information = std::move(type.type_information);
2597 assigned_ = type.assigned_;
2598
2599 return *this;
2600 }
2601
2605 virtual FASTDDS_EXPORTED_API ~TypeInformationParameter() override = default;
2606
2607 inline void clear() override
2608 {
2609 *this = TypeInformationParameter();
2610 }
2617 FASTDDS_EXPORTED_API bool assigned() const
2618 {
2619 return assigned_;
2620 }
2621
2627 FASTDDS_EXPORTED_API void assigned(
2628 bool value)
2629 {
2630 assigned_ = value;
2632
2633 FASTDDS_EXPORTED_API TypeInformationParameter& operator =(
2634 const TypeInformation& type_info)
2635 {
2636 type_information = type_info;
2637 assigned_ = true;
2638 return *this;
2639 }
2640
2641private:
2644 bool assigned_;
2645};
2646
2647} // namespace xtypes
2648
2654
2656class WireProtocolConfigQos : public QosPolicy
2657{
2658
2659public:
2660
2664 FASTDDS_EXPORTED_API WireProtocolConfigQos()
2665 : QosPolicy(false)
2666 , participant_id(-1)
2668 }
2669
2673 virtual FASTDDS_EXPORTED_API ~WireProtocolConfigQos() = default;
2675 bool operator ==(
2676 const WireProtocolConfigQos& b) const
2678 return (this->prefix == b.prefix) &&
2679 (this->participant_id == b.participant_id) &&
2680 (this->builtin == b.builtin) &&
2681 (this->port == b.port) &&
2686 QosPolicy::operator ==(b);
2687 }
2688
2689 inline void clear() override
2690 {
2692 std::swap(*this, reset);
2693 }
2694
2697
2699 int32_t participant_id;
2703
2706
2712
2718
2723
2727 bool ignore_non_matching_locators = false;
2728};
2732{
2733public:
2734
2738 FASTDDS_EXPORTED_API TransportConfigQos()
2739 : QosPolicy(false)
2751 virtual FASTDDS_EXPORTED_API ~TransportConfigQos() = default;
2752
2753 bool operator ==(
2754 const TransportConfigQos& b) const
2755 {
2756 return (this->user_transports == b.user_transports) &&
2762 (this->netmask_filter == b.netmask_filter) &&
2764 }
2766 inline void clear() override
2767 {
2769 std::swap(*this, reset);
2770 }
2771
2773 std::vector<std::shared_ptr<fastdds::rtps::TransportDescriptorInterface>> user_transports;
2774
2777
2782 uint32_t send_socket_buffer_size;
2788
2803
2806{
2807public:
2809 FASTDDS_EXPORTED_API RTPSEndpointQos() = default;
2810
2811 virtual FASTDDS_EXPORTED_API ~RTPSEndpointQos() = default;
2812
2813 bool operator ==(
2814 const RTPSEndpointQos& b) const
2815 {
2816 return (this->unicast_locator_list == b.unicast_locator_list) &&
2821 (this->user_defined_id == b.user_defined_id) &&
2822 (this->entity_id == b.entity_id) &&
2824 }
2825
2828
2862 , reader_filters_allocation(0, 32u, 1u)
2863 {
2864 }
2882};
2883
2888{
2893 AUTO = 0x01,
2898 ON = 0x02,
2902 OFF = 0x03
2903};
2904
2905
2911class DataSharingQosPolicy : public Parameter_t, public QosPolicy
2912{
2913public:
2918 FASTDDS_EXPORTED_API DataSharingQosPolicy()
2920 , QosPolicy(true)
2921 {
2922 //Needed to generate the automatic domain ID
2923 automatic();
2924 }
2925
2929 virtual FASTDDS_EXPORTED_API ~DataSharingQosPolicy() = default;
2930
2936 FASTDDS_EXPORTED_API DataSharingQosPolicy(
2937 const DataSharingQosPolicy& b)
2938 : Parameter_t(b)
2939 , QosPolicy(b)
2940 , kind_(b.kind())
2941 , shm_directory_ (b.shm_directory())
2942 , max_domains_ (b.max_domains())
2943 , domain_ids_(b.max_domains() != 0 ?
2944 b.max_domains() :
2945 b.domain_ids().size())
2946 {
2947 domain_ids_ = b.domain_ids();
2948 }
2949
2950 FASTDDS_EXPORTED_API DataSharingQosPolicy& operator =(
2951 const DataSharingQosPolicy& b)
2952 {
2954 Parameter_t::operator =(b);
2955 kind_ = b.kind();
2956 shm_directory_ = b.shm_directory();
2957 max_domains_ = b.max_domains();
2958 domain_ids_.reserve(max_domains_ != 0 ?
2959 max_domains_ :
2960 b.domain_ids().size());
2961 domain_ids_ = b.domain_ids();
2962 data_sharing_listener_thread_ = b.data_sharing_listener_thread();
2963
2964 return *this;
2966
2967 bool operator ==(
2968 const DataSharingQosPolicy& b) const
2969 {
2970 return kind_ == b.kind_ &&
2971 shm_directory_ == b.shm_directory_ &&
2972 domain_ids_ == b.domain_ids_ &&
2973 data_sharing_listener_thread_ == b.data_sharing_listener_thread_ &&
2976 }
2977
2978 inline void clear() override
2979 {
2981 std::swap(*this, reset);
2982 }
2983
2987 FASTDDS_EXPORTED_API const DataSharingKind& kind() const
2988 {
2989 return kind_;
2990 }
2995 FASTDDS_EXPORTED_API const std::string& shm_directory() const
2996 {
2997 return shm_directory_;
2998 }
3013 FASTDDS_EXPORTED_API const std::vector<uint64_t>& domain_ids() const
3014 {
3015 return domain_ids_;
3016 }
3017
3021 FASTDDS_EXPORTED_API void set_max_domains(
3022 uint32_t size)
3023 {
3024 domain_ids_.reserve(size);
3025 max_domains_ = size;
3026 }
3027
3031 FASTDDS_EXPORTED_API const uint32_t& max_domains() const
3033 return max_domains_;
3034 }
3035
3042 FASTDDS_EXPORTED_API void automatic()
3043 {
3044 setup (AUTO, "", std::vector<uint16_t>());
3046
3054 FASTDDS_EXPORTED_API void automatic(
3055 const std::vector<uint16_t>& domain_ids)
3056 {
3057 setup (AUTO, "", domain_ids);
3058 }
3059
3067 FASTDDS_EXPORTED_API void automatic(
3068 const std::string& directory)
3069 {
3070 setup (AUTO, directory, std::vector<uint16_t>());
3071 }
3079 FASTDDS_EXPORTED_API void automatic(
3080 const std::string& directory,
3081 const std::vector<uint16_t>& domain_ids)
3082 {
3083 setup (AUTO, directory, domain_ids);
3084 }
3085
3094 FASTDDS_EXPORTED_API void on(
3095 const std::string& directory)
3096 {
3097 // TODO [ILG]: This parameter is unused right now. Activate the assert once it is used
3098 //assert(!directory.empty());
3099 setup (ON, directory, std::vector<uint16_t>());
3100 }
3101
3109 FASTDDS_EXPORTED_API void on(
3110 const std::string& directory,
3111 const std::vector<uint16_t>& domain_ids)
3112 {
3113 // TODO [ILG]: This parameter is unused right now. Activate the assert once it is used
3114 //assert(!directory.empty());
3115 setup (ON, directory, domain_ids);
3116 }
3117
3121 FASTDDS_EXPORTED_API void off()
3122 {
3123 setup (OFF, "", std::vector<uint16_t>());
3124 }
3125
3131 FASTDDS_EXPORTED_API void add_domain_id(
3132 uint16_t id)
3134 if (max_domains_ == 0 || domain_ids_.size() < max_domains_)
3135 {
3136 domain_ids_.push_back(id);
3137 }
3138 }
3139
3140 // Not on the exported API, but must be public for other internal classes
3141 void add_domain_id(
3142 uint64_t id)
3144 if (max_domains_ == 0 || domain_ids_.size() < max_domains_)
3145 {
3146 domain_ids_.push_back(id);
3147 }
3148 }
3149
3156 {
3157 return data_sharing_listener_thread_;
3158 }
3159
3166 {
3167 return data_sharing_listener_thread_;
3168 }
3169
3176 const rtps::ThreadSettings& value)
3177 {
3178 data_sharing_listener_thread_ = value;
3179 }
3180
3181private:
3182
3183 void setup(
3184 const DataSharingKind& kind,
3185 const std::string& directory,
3186 const std::vector<uint16_t>& domain_ids)
3187 {
3188 kind_ = kind;
3189 shm_directory_ = directory;
3190 domain_ids_.clear();
3191
3192 for (uint16_t id : domain_ids)
3193 {
3194 add_domain_id(id);
3195 }
3196 }
3197
3199 DataSharingKind kind_ = AUTO;
3200
3202 std::string shm_directory_;
3203
3205 uint32_t max_domains_ = 0;
3206
3208 std::vector<uint64_t> domain_ids_;
3209
3211 rtps::ThreadSettings data_sharing_listener_thread_;
3212};
3213
3214
3215} // namespace dds
3216} // namespace fastdds
3217} // namespace eprosima
3218
3219#endif // FASTDDS_DDS_CORE_POLICY__QOSPOLICIES_HPP
Resource limited wrapper of std::vector.
Definition ResourceLimitedVector.hpp:59
size_type size() const noexcept
Definition ResourceLimitedVector.hpp:479
configuration_type configuration_
Definition ResourceLimitedVector.hpp:543
std::vector< fastdds::rtps::octet, std::allocator< fastdds::rtps::octet > > collection_type
Definition ResourceLimitedVector.hpp:63
void clear()
Definition ResourceLimitedVector.hpp:494
void assign(InputIterator first, InputIterator last)
Assign vector content.
Definition ResourceLimitedVector.hpp:318
collection_type collection_
Definition ResourceLimitedVector.hpp:544
value_type * data()
Definition ResourceLimitedVector.hpp:517
With multiple standard data Representations available, and vendor-specific extensions possible,...
Definition QosPolicies.hpp:2070
bool operator==(const DataRepresentationQosPolicy &b) const
Compares the given policy to check if it's equal.
Definition QosPolicies.hpp:2096
virtual FASTDDS_EXPORTED_API ~DataRepresentationQosPolicy() override=default
Destructor.
FASTDDS_EXPORTED_API DataRepresentationQosPolicy()
Constructor.
Definition QosPolicies.hpp:2079
std::vector< DataRepresentationId_t > m_value
List of DataRepresentationId. By default, empty list.
Definition QosPolicies.hpp:2074
void clear() override
Clears the QosPolicy object.
Definition QosPolicies.hpp:2104
Qos Policy to configure the data sharing.
Definition QosPolicies.hpp:2890
FASTDDS_EXPORTED_API const std::vector< uint64_t > & domain_ids() const
Gets the set of DataSharing domain IDs.
Definition QosPolicies.hpp:2991
FASTDDS_EXPORTED_API const uint32_t & max_domains() const
Definition QosPolicies.hpp:3009
bool operator==(const DataSharingQosPolicy &b) const
Definition QosPolicies.hpp:2945
FASTDDS_EXPORTED_API const DataSharingKind & kind() const
Definition QosPolicies.hpp:2965
FASTDDS_EXPORTED_API DataSharingQosPolicy()
Constructor.
Definition QosPolicies.hpp:2896
FASTDDS_EXPORTED_API const std::string & shm_directory() const
Definition QosPolicies.hpp:2973
rtps::ThreadSettings & data_sharing_listener_thread()
Getter for DataSharing listener thread ThreadSettings.
Definition QosPolicies.hpp:3133
FASTDDS_EXPORTED_API DataSharingQosPolicy & operator=(const DataSharingQosPolicy &b)
Definition QosPolicies.hpp:2928
virtual FASTDDS_EXPORTED_API ~DataSharingQosPolicy()=default
Destructor.
FASTDDS_EXPORTED_API void add_domain_id(uint16_t id)
Adds a user-specific DataSharing domain ID.
Definition QosPolicies.hpp:3109
FASTDDS_EXPORTED_API void off()
Configures the DataSharing in disabled mode.
Definition QosPolicies.hpp:3099
FASTDDS_EXPORTED_API void set_max_domains(uint32_t size)
Definition QosPolicies.hpp:2999
FASTDDS_EXPORTED_API void on(const std::string &directory)
Configures the DataSharing in active mode.
Definition QosPolicies.hpp:3072
void clear() override
Clears the QosPolicy object.
Definition QosPolicies.hpp:2956
FASTDDS_EXPORTED_API void automatic()
Configures the DataSharing in automatic mode.
Definition QosPolicies.hpp:3020
DataReader expects a new sample updating the value of each instance at least once every deadline peri...
Definition QosPolicies.hpp:361
bool operator==(const DeadlineQosPolicy &b) const
Definition QosPolicies.hpp:379
fastdds::dds::Duration_t period
Maximum time expected between samples.
Definition QosPolicies.hpp:401
FASTDDS_EXPORTED_API DeadlineQosPolicy()
Constructor.
Definition QosPolicies.hpp:367
virtual FASTDDS_EXPORTED_API ~DeadlineQosPolicy()=default
Destructor.
void clear() override
Clears the QosPolicy object.
Definition QosPolicies.hpp:387
Controls the criteria used to determine the logical order among changes made by Publisher entities to...
Definition QosPolicies.hpp:717
bool operator==(const DestinationOrderQosPolicy &b) const
Definition QosPolicies.hpp:735
DestinationOrderQosPolicyKind kind
DestinationOrderQosPolicyKind. By default, BY_RECEPTION_TIMESTAMP_DESTINATIONORDER_QOS.
Definition QosPolicies.hpp:752
virtual FASTDDS_EXPORTED_API ~DestinationOrderQosPolicy()=default
Destructor.
FASTDDS_EXPORTED_API DestinationOrderQosPolicy()
Constructor.
Definition QosPolicies.hpp:723
void clear() override
Clears the QosPolicy object.
Definition QosPolicies.hpp:743
Class DisablePositiveACKsQosPolicy to disable sending of positive ACKs.
Definition QosPolicies.hpp:2222
bool operator==(const DisablePositiveACKsQosPolicy &b) const
Definition QosPolicies.hpp:2241
bool enabled
True if this QoS is enabled. By default, false.
Definition QosPolicies.hpp:2259
fastdds::dds::Duration_t duration
The duration to keep samples for (not serialized as not needed by reader). By default,...
Definition QosPolicies.hpp:2261
FASTDDS_EXPORTED_API DisablePositiveACKsQosPolicy()
Constructor.
Definition QosPolicies.hpp:2228
void clear() override
Clears the QosPolicy object.
Definition QosPolicies.hpp:2250
virtual FASTDDS_EXPORTED_API ~DisablePositiveACKsQosPolicy()=default
Destructor.
This policy expresses if the data should ‘outlive’ their writing time.
Definition QosPolicies.hpp:276
virtual FASTDDS_EXPORTED_API ~DurabilityQosPolicy()=default
Destructor.
fastdds::rtps::DurabilityKind_t durabilityKind() const
Translates kind to rtps layer equivalent.
Definition QosPolicies.hpp:299
DurabilityQosPolicyKind_t kind
DurabilityQosPolicyKind.
Definition QosPolicies.hpp:350
FASTDDS_EXPORTED_API DurabilityQosPolicy()
Constructor.
Definition QosPolicies.hpp:282
bool operator==(const DurabilityQosPolicy &b) const
Definition QosPolicies.hpp:311
void durabilityKind(const fastdds::rtps::DurabilityKind_t new_kind)
Set kind passing the rtps layer equivalent kind.
Definition QosPolicies.hpp:324
void clear() override
Clears the QosPolicy object.
Definition QosPolicies.hpp:338
Specifies the configuration of the durability service.
Definition QosPolicies.hpp:1787
virtual FASTDDS_EXPORTED_API ~DurabilityServiceQosPolicy()=default
Destructor.
int32_t max_samples_per_instance
Control the ResourceLimitsQos of the implied DataReader that stores the data within the durability se...
Definition QosPolicies.hpp:1866
FASTDDS_EXPORTED_API DurabilityServiceQosPolicy()
Constructor.
Definition QosPolicies.hpp:1793
int32_t max_samples
Control the ResourceLimitsQos of the implied DataReader that stores the data within the durability se...
Definition QosPolicies.hpp:1853
int32_t max_instances
Control the ResourceLimitsQos of the implied DataReader that stores the data within the durability se...
Definition QosPolicies.hpp:1859
fastdds::dds::Duration_t service_cleanup_delay
Control when the service is able to remove all information regarding a data-instance.
Definition QosPolicies.hpp:1833
HistoryQosPolicyKind history_kind
Controls the HistoryQosPolicy of the fictitious DataReader that stores the data within the durability...
Definition QosPolicies.hpp:1839
int32_t history_depth
Number of most recent values that should be maintained on the History.
Definition QosPolicies.hpp:1845
bool operator==(const DurabilityServiceQosPolicy &b) const
Definition QosPolicies.hpp:1809
void clear() override
Clears the QosPolicy object.
Definition QosPolicies.hpp:1821
Controls the behavior of the entity when acting as a factory for other entities.
Definition QosPolicies.hpp:187
bool operator==(const EntityFactoryQosPolicy &b) const
Definition QosPolicies.hpp:223
FASTDDS_EXPORTED_API EntityFactoryQosPolicy(bool autoenable)
Constructor.
Definition QosPolicies.hpp:210
FASTDDS_EXPORTED_API EntityFactoryQosPolicy()
Constructor without parameters.
Definition QosPolicies.hpp:200
bool autoenable_created_entities
Specifies whether the entity acting as a factory automatically enables the instances it creates.
Definition QosPolicies.hpp:195
virtual FASTDDS_EXPORTED_API ~EntityFactoryQosPolicy()
Destructor.
Definition QosPolicies.hpp:219
void clear()
Definition QosPolicies.hpp:230
Class GenericDataQosPolicy, base class to transmit user data during the discovery phase.
Definition QosPolicies.hpp:761
virtual FASTDDS_EXPORTED_API ~GenericDataQosPolicy()=default
FASTDDS_EXPORTED_API const collection_type & getValue() const
Returns raw data vector.
Definition QosPolicies.hpp:960
FASTDDS_EXPORTED_API GenericDataQosPolicy(const GenericDataQosPolicy &data)
Construct from another GenericDataQosPolicy.
Definition QosPolicies.hpp:791
FASTDDS_EXPORTED_API GenericDataQosPolicy(ParameterId_t pid, uint16_t in_length)
Definition QosPolicies.hpp:774
FASTDDS_EXPORTED_API collection_type & data_vec()
Returns raw data vector.
Definition QosPolicies.hpp:934
FASTDDS_EXPORTED_API GenericDataQosPolicy(ParameterId_t pid)
Definition QosPolicies.hpp:766
void resize(size_t new_size)
Definition QosPolicies.hpp:899
const collection_type & dataVec() const
Definition QosPolicies.hpp:908
FASTDDS_EXPORTED_API const collection_type & data_vec() const
Returns raw data vector.
Definition QosPolicies.hpp:924
FASTDDS_EXPORTED_API void data_vec(const collection_type &vec)
Sets raw data vector.
Definition QosPolicies.hpp:944
FASTDDS_EXPORTED_API GenericDataQosPolicy(ParameterId_t pid, const collection_type &data)
Construct from underlying collection type.
Definition QosPolicies.hpp:808
void set_max_size(size_t size)
Set the maximum size of the user data and reserves memory for that much.
Definition QosPolicies.hpp:885
bool operator==(const GenericDataQosPolicy &b) const
Definition QosPolicies.hpp:866
FASTDDS_EXPORTED_API void setValue(const collection_type &vec)
Sets raw data vector.
Definition QosPolicies.hpp:970
void clear() override
Clears the QosPolicy object.
Definition QosPolicies.hpp:913
GenericDataQosPolicy & operator=(const collection_type &b)
Copies data from underlying collection type.
Definition QosPolicies.hpp:832
Specifies the behavior of the Service in the case where the value of a sample changes (one or more ti...
Definition QosPolicies.hpp:1649
bool operator==(const HistoryQosPolicy &b) const
Definition QosPolicies.hpp:1668
HistoryQosPolicyKind kind
HistoryQosPolicyKind. By default, KEEP_LAST_HISTORY_QOS.
Definition QosPolicies.hpp:1686
int32_t depth
History depth.
Definition QosPolicies.hpp:1692
FASTDDS_EXPORTED_API HistoryQosPolicy()
Constructor.
Definition QosPolicies.hpp:1655
virtual FASTDDS_EXPORTED_API ~HistoryQosPolicy()=default
Destructor.
void clear() override
Clears the QosPolicy object.
Definition QosPolicies.hpp:1677
Specifies the maximum acceptable delay from the time the data is written until the data is inserted i...
Definition QosPolicies.hpp:414
FASTDDS_EXPORTED_API LatencyBudgetQosPolicy()
Constructor.
Definition QosPolicies.hpp:420
bool operator==(const LatencyBudgetQosPolicy &b) const
Definition QosPolicies.hpp:432
fastdds::dds::Duration_t duration
Maximum acceptable delay from the time data is written until it is received. By default,...
Definition QosPolicies.hpp:449
virtual FASTDDS_EXPORTED_API ~LatencyBudgetQosPolicy()=default
Destructor.
void clear() override
Clears the QosPolicy object.
Definition QosPolicies.hpp:440
Specifies the maximum duration of validity of the data written by the DataWriter.
Definition QosPolicies.hpp:1875
FASTDDS_EXPORTED_API LifespanQosPolicy()
Constructor.
Definition QosPolicies.hpp:1881
virtual FASTDDS_EXPORTED_API ~LifespanQosPolicy()=default
Destructor.
fastdds::dds::Duration_t duration
Period of validity. By default, dds::c_TimeInfinite.
Definition QosPolicies.hpp:1910
bool operator==(const LifespanQosPolicy &b) const
Definition QosPolicies.hpp:1893
void clear() override
Clears the QosPolicy object.
Definition QosPolicies.hpp:1901
Determines the mechanism and parameters used by the application to determine whether an Entity is “ac...
Definition QosPolicies.hpp:486
virtual FASTDDS_EXPORTED_API ~LivelinessQosPolicy()=default
Destructor.
LivelinessQosPolicyKind kind
Liveliness kind By default, AUTOMATIC_LIVELINESS.
Definition QosPolicies.hpp:525
FASTDDS_EXPORTED_API LivelinessQosPolicy()
Constructor.
Definition QosPolicies.hpp:492
fastdds::dds::Duration_t lease_duration
Period within which liveliness should be asserted.
Definition QosPolicies.hpp:532
bool operator==(const LivelinessQosPolicy &b) const
Definition QosPolicies.hpp:506
fastdds::dds::Duration_t announcement_period
The period for automatic assertion of liveliness.
Definition QosPolicies.hpp:539
void clear() override
Clears the QosPolicy object.
Definition QosPolicies.hpp:516
Specifies whether it is allowed for multiple DataWriters to write the same instance of the data and i...
Definition QosPolicies.hpp:650
FASTDDS_EXPORTED_API OwnershipQosPolicy()
Constructor.
Definition QosPolicies.hpp:656
bool operator==(const OwnershipQosPolicy &b) const
Definition QosPolicies.hpp:668
OwnershipQosPolicyKind kind
OwnershipQosPolicyKind.
Definition QosPolicies.hpp:685
void clear() override
Clears the QosPolicy object.
Definition QosPolicies.hpp:676
virtual FASTDDS_EXPORTED_API ~OwnershipQosPolicy()=default
Destructor.
Specifies the value of the “strength” used to arbitrate among multiple DataWriter objects that attemp...
Definition QosPolicies.hpp:1921
FASTDDS_EXPORTED_API OwnershipStrengthQosPolicy()
Constructor.
Definition QosPolicies.hpp:1927
virtual FASTDDS_EXPORTED_API ~OwnershipStrengthQosPolicy()=default
Destructor.
uint32_t value
Strength By default, 0.
Definition QosPolicies.hpp:1956
void clear() override
Clears the QosPolicy object.
Definition QosPolicies.hpp:1947
bool operator==(const OwnershipStrengthQosPolicy &b) const
Definition QosPolicies.hpp:1939
Base Parameter class with parameter PID and parameter length in bytes.
Definition ParameterTypes.hpp:183
ParameterId_t Pid
Parameter ID. By default, PID_PAD.
Definition ParameterTypes.hpp:226
FASTDDS_EXPORTED_API Parameter_t()
Constructor without parameters.
Definition ParameterTypes.hpp:189
uint16_t length
Parameter length. By default, 0.
Definition ParameterTypes.hpp:228
bool operator==(const Parameter_t &b) const
Definition ParameterTypes.hpp:216
Definition QosPolicies.hpp:1210
bool operator==(const Partition_t &rhs) const
Definition QosPolicies.hpp:1238
bool operator!=(const Partition_t &rhs) const
Definition QosPolicies.hpp:1245
uint32_t size() const
Getter for the size.
Definition QosPolicies.hpp:1256
const char * name() const
Getter for the partition name.
Definition QosPolicies.hpp:1266
pointer operator->()
Definition QosPolicies.hpp:1329
size_t difference_type
Definition QosPolicies.hpp:1295
self_type operator++()
Definition QosPolicies.hpp:1310
bool operator==(const self_type &rhs) const
Definition QosPolicies.hpp:1334
std::forward_iterator_tag iterator_category
Definition QosPolicies.hpp:1296
const Partition_t value_type
Definition QosPolicies.hpp:1292
bool operator!=(const self_type &rhs) const
Definition QosPolicies.hpp:1340
reference operator*()
Definition QosPolicies.hpp:1324
const Partition_t reference
Definition QosPolicies.hpp:1293
const_iterator self_type
Definition QosPolicies.hpp:1291
void advance()
Shift the pointer to the next element.
Definition QosPolicies.hpp:1351
const Partition_t * pointer
Definition QosPolicies.hpp:1294
Set of strings that introduces a logical partition among the topics visible by the Publisher and Subs...
Definition QosPolicies.hpp:1284
bool operator==(const PartitionQosPolicy &b) const
Definition QosPolicies.hpp:1419
FASTDDS_EXPORTED_API const std::vector< std::string > names() const
Returns partition names.
Definition QosPolicies.hpp:1576
const_iterator begin() const
Getter for the first position of the partition list.
Definition QosPolicies.hpp:1449
FASTDDS_EXPORTED_API void push_back(const char *name)
Appends a name to the list of partition names.
Definition QosPolicies.hpp:1511
uint32_t size() const
Getter for the number of partitions.
Definition QosPolicies.hpp:1469
FASTDDS_EXPORTED_API const std::vector< std::string > getNames() const
Returns partition names.
Definition QosPolicies.hpp:1555
uint32_t max_size() const
Getter for the maximum size (in bytes)
Definition QosPolicies.hpp:1501
virtual FASTDDS_EXPORTED_API ~PartitionQosPolicy()=default
Destructor.
FASTDDS_EXPORTED_API void setNames(std::vector< std::string > &nam)
Overrides partition names.
Definition QosPolicies.hpp:1565
void set_max_size(uint32_t size)
Setter for the maximum size reserved for partitions (in bytes)
Definition QosPolicies.hpp:1489
PartitionQosPolicy & operator=(const PartitionQosPolicy &b)
Definition QosPolicies.hpp:1429
const_iterator end() const
Getter for the end of the partition list.
Definition QosPolicies.hpp:1459
uint32_t empty() const
Check if the set is empty.
Definition QosPolicies.hpp:1479
FASTDDS_EXPORTED_API void clear() override
Clears list of partition names.
Definition QosPolicies.hpp:1543
FASTDDS_EXPORTED_API PartitionQosPolicy()
Constructor without parameters.
Definition QosPolicies.hpp:1373
Specifies how the samples representing changes to data instances are presented to the subscribing app...
Definition QosPolicies.hpp:1154
bool coherent_access
Specifies support coherent access.
Definition QosPolicies.hpp:1199
virtual FASTDDS_EXPORTED_API ~PresentationQosPolicy()=default
Destructor.
bool operator==(const PresentationQosPolicy &b) const
Definition QosPolicies.hpp:1174
FASTDDS_EXPORTED_API PresentationQosPolicy()
Constructor without parameters.
Definition QosPolicies.hpp:1160
bool ordered_access
Specifies support for ordered access to the samples received at the subscription end.
Definition QosPolicies.hpp:1205
PresentationQosPolicyAccessScopeKind access_scope
Access Scope Kind By default, INSTANCE_PRESENTATION_QOS.
Definition QosPolicies.hpp:1193
void clear() override
Clears the QosPolicy object.
Definition QosPolicies.hpp:1184
Class PublishModeQosPolicy, defines the publication mode for a specific writer.
Definition QosPolicies.hpp:2018
std::string flow_controller_name
Name of the flow controller used when publish mode kind is ASYNCHRONOUS_PUBLISH_MODE.
Definition QosPolicies.hpp:2028
PublishModeQosPolicyKind kind
PublishModeQosPolicyKind By default, SYNCHRONOUS_PUBLISH_MODE.
Definition QosPolicies.hpp:2022
bool operator==(const PublishModeQosPolicy &b) const
Definition QosPolicies.hpp:2036
void clear() override
Clears the QosPolicy object.
Definition QosPolicies.hpp:2030
Class QosPolicy, base for all QoS policies defined for Writers and Readers.
Definition QosPolicies.hpp:109
bool hasChanged
Boolean that indicates if the Qos has been changed with respect to the default Qos.
Definition QosPolicies.hpp:113
QosPolicy(bool send_always)
Constructor.
Definition QosPolicies.hpp:129
bool send_always_
Boolean that indicates if the Qos has to be sent even if it is not changed.
Definition QosPolicies.hpp:177
virtual void clear()=0
Clears the QosPolicy object.
QosPolicy(const QosPolicy &b)=default
Copy Constructor.
QosPolicy & operator=(const QosPolicy &b)=default
virtual bool send_always() const
Whether it should always be sent.
Definition QosPolicies.hpp:164
QosPolicy()
Constructor without parameters.
Definition QosPolicies.hpp:118
virtual ~QosPolicy()=default
Destructor.
bool operator==(const QosPolicy &b) const
Definition QosPolicies.hpp:149
Qos Policy to configure the endpoint.
Definition QosPolicies.hpp:2784
fastdds::rtps::ExternalLocators external_unicast_locators
The collection of external locators to use for communication.
Definition QosPolicies.hpp:2814
int16_t entity_id
Entity ID, if the user wants to specify the EntityID of the endpoint. By default,...
Definition QosPolicies.hpp:2823
fastdds::rtps::MemoryManagementPolicy_t history_memory_policy
Underlying History memory policy. By default, PREALLOCATED_WITH_REALLOC_MEMORY_MODE.
Definition QosPolicies.hpp:2826
int16_t user_defined_id
User Defined ID, used for StaticEndpointDiscovery. By default, -1.
Definition QosPolicies.hpp:2820
rtps::LocatorList multicast_locator_list
Multicast locator list.
Definition QosPolicies.hpp:2808
FASTDDS_EXPORTED_API RTPSEndpointQos()=default
virtual FASTDDS_EXPORTED_API ~RTPSEndpointQos()=default
rtps::LocatorList remote_locator_list
Remote locator list.
Definition QosPolicies.hpp:2811
bool ignore_non_matching_locators
Whether locators that don't match with the announced locators should be kept.
Definition QosPolicies.hpp:2817
bool operator==(const RTPSEndpointQos &b) const
Definition QosPolicies.hpp:2791
rtps::LocatorList unicast_locator_list
Unicast locator list.
Definition QosPolicies.hpp:2805
Indicates the reliability of the endpoint.
Definition QosPolicies.hpp:568
FASTDDS_EXPORTED_API ReliabilityQosPolicy()
Constructor.
Definition QosPolicies.hpp:574
virtual FASTDDS_EXPORTED_API ~ReliabilityQosPolicy()=default
Destructor.
fastdds::dds::Duration_t max_blocking_time
Defines the maximum period of time certain methods will be blocked.
Definition QosPolicies.hpp:620
bool operator==(const ReliabilityQosPolicy &b) const
Definition QosPolicies.hpp:587
ReliabilityQosPolicyKind kind
Defines the reliability kind of the endpoint.
Definition QosPolicies.hpp:608
void clear() override
Clears the QosPolicy object.
Definition QosPolicies.hpp:596
Specifies the resources that the Service can consume in order to meet the requested QoS.
Definition QosPolicies.hpp:1701
bool operator==(const ResourceLimitsQosPolicy &b) const
Definition QosPolicies.hpp:1757
FASTDDS_EXPORTED_API ResourceLimitsQosPolicy()
Constructor.
Definition QosPolicies.hpp:1741
int32_t max_samples_per_instance
Represents the maximum number of samples of any one instance a DataWriter(or DataReader) can manage.
Definition QosPolicies.hpp:1726
int32_t allocated_samples
Number of samples currently allocated.
Definition QosPolicies.hpp:1731
int32_t extra_samples
Represents the extra number of samples available once the max_samples have been reached in the histor...
Definition QosPolicies.hpp:1736
int32_t max_samples
Specifies the maximum number of data-samples the DataWriter (or DataReader) can manage across all the...
Definition QosPolicies.hpp:1712
virtual FASTDDS_EXPORTED_API ~ResourceLimitsQosPolicy()=default
Destructor.
int32_t max_instances
Represents the maximum number of instances DataWriter (or DataReader) can manage.
Definition QosPolicies.hpp:1719
void clear() override
Clears the QosPolicy object.
Definition QosPolicies.hpp:1768
Filter that allows a DataReader to specify that it is interested only in (potentially) a subset of th...
Definition QosPolicies.hpp:1080
fastdds::dds::Duration_t minimum_separation
Minimum interval between samples. By default, dds::c_TimeZero (the DataReader is interested in all va...
Definition QosPolicies.hpp:1115
bool operator==(const TimeBasedFilterQosPolicy &b) const
Definition QosPolicies.hpp:1098
FASTDDS_EXPORTED_API TimeBasedFilterQosPolicy()
Constructor.
Definition QosPolicies.hpp:1086
virtual FASTDDS_EXPORTED_API ~TimeBasedFilterQosPolicy()=default
Destructor.
void clear() override
Clears the QosPolicy object.
Definition QosPolicies.hpp:1106
Qos Policy to configure the transport layer.
Definition QosPolicies.hpp:2710
std::vector< std::shared_ptr< fastdds::rtps::TransportDescriptorInterface > > user_transports
User defined transports to use alongside or in place of builtins.
Definition QosPolicies.hpp:2751
bool operator==(const TransportConfigQos &b) const
Definition QosPolicies.hpp:2731
fastdds::rtps::NetmaskFilterKind netmask_filter
Netmask filter configuration.
Definition QosPolicies.hpp:2779
uint32_t listen_socket_buffer_size
Listen socket buffer for all listen resources.
Definition QosPolicies.hpp:2765
bool use_builtin_transports
Set as false to disable the default UDPv4 implementation. By default, true.
Definition QosPolicies.hpp:2754
uint32_t max_msg_size_no_frag
Maximum message size used to avoid fragmentation, set ONLY in LARGE_DATA.
Definition QosPolicies.hpp:2776
rtps::ThreadSettings builtin_transports_reception_threads_
Thread settings for the builtin transports reception threads.
Definition QosPolicies.hpp:2768
FASTDDS_EXPORTED_API TransportConfigQos()
Constructor.
Definition QosPolicies.hpp:2716
uint32_t send_socket_buffer_size
Send socket buffer size for the send resource.
Definition QosPolicies.hpp:2760
virtual FASTDDS_EXPORTED_API ~TransportConfigQos()=default
Destructor.
void clear() override
Clears the QosPolicy object.
Definition QosPolicies.hpp:2744
This policy is a hint to the infrastructure as to how to set the priority of the underlying transport...
Definition QosPolicies.hpp:1968
bool operator==(const TransportPriorityQosPolicy &b) const
Definition QosPolicies.hpp:1989
FASTDDS_EXPORTED_API TransportPriorityQosPolicy()
Constructor.
Definition QosPolicies.hpp:1977
uint32_t value
Priority By default, 0.
Definition QosPolicies.hpp:1972
void clear() override
Clears the QosPolicy object.
Definition QosPolicies.hpp:1997
virtual FASTDDS_EXPORTED_API ~TransportPriorityQosPolicy()=default
Destructor.
The TypeConsistencyEnforcementQosPolicy defines the rules for determining whether the type used to pu...
Definition QosPolicies.hpp:2132
bool m_ignore_member_names
This option controls whether member names are taken into consideration for type assignability.
Definition QosPolicies.hpp:2161
FASTDDS_EXPORTED_API TypeConsistencyEnforcementQosPolicy()
Constructor.
Definition QosPolicies.hpp:2178
bool m_ignore_string_bounds
This option controls whether string bounds are taken into consideration for type assignability.
Definition QosPolicies.hpp:2154
bool m_ignore_sequence_bounds
This option controls whether sequence bounds are taken into consideration for type assignability.
Definition QosPolicies.hpp:2145
bool m_prevent_type_widening
This option controls whether type widening is allowed.
Definition QosPolicies.hpp:2167
bool operator==(const TypeConsistencyEnforcementQosPolicy &b) const
Definition QosPolicies.hpp:2195
bool m_force_type_validation
This option requires type information to be available in order to complete matching between a DataWri...
Definition QosPolicies.hpp:2173
virtual FASTDDS_EXPORTED_API ~TypeConsistencyEnforcementQosPolicy() override=default
Destructor.
TypeConsistencyKind m_kind
TypeConsistencyKind. By default, ALLOW_TYPE_COERCION.
Definition QosPolicies.hpp:2136
void clear() override
Clears the QosPolicy object.
Definition QosPolicies.hpp:2208
Class TypeIdV1.
Definition QosPolicies.hpp:2268
virtual FASTDDS_EXPORTED_API ~TypeIdV1() override=default
Destructor.
xtypes::TypeIdentifier m_type_identifier
Type Identifier.
Definition QosPolicies.hpp:2272
FASTDDS_EXPORTED_API TypeIdV1()
Constructor without parameters.
Definition QosPolicies.hpp:2278
FASTDDS_EXPORTED_API TypeIdV1 & operator=(const TypeIdV1 &type)
Definition QosPolicies.hpp:2324
FASTDDS_EXPORTED_API const xtypes::TypeIdentifier & get() const
Getter for the TypeIndentifier.
Definition QosPolicies.hpp:2370
void clear() override
Clears the QosPolicy object.
Definition QosPolicies.hpp:2353
Class TypeObjectV1.
Definition QosPolicies.hpp:2381
virtual FASTDDS_EXPORTED_API ~TypeObjectV1() override=default
Destructor.
FASTDDS_EXPORTED_API TypeObjectV1 & operator=(const TypeObjectV1 &type)
Definition QosPolicies.hpp:2436
xtypes::TypeObject m_type_object
Type Object.
Definition QosPolicies.hpp:2385
FASTDDS_EXPORTED_API TypeObjectV1()
Constructor.
Definition QosPolicies.hpp:2390
FASTDDS_EXPORTED_API const xtypes::TypeObject & get() const
Getter for the TypeObject.
Definition QosPolicies.hpp:2482
void clear() override
Clears the QosPolicy object.
Definition QosPolicies.hpp:2465
Qos Policy that configures the wire protocol.
Definition QosPolicies.hpp:2635
fastdds::rtps::GuidPrefix_t prefix
Optionally allows user to define the GuidPrefix_t.
Definition QosPolicies.hpp:2674
FASTDDS_EXPORTED_API WireProtocolConfigQos()
Constructor.
Definition QosPolicies.hpp:2642
rtps::LocatorList default_multicast_locator_list
Default list of Multicast Locators to be used for any Endpoint defined inside this RTPSParticipant in...
Definition QosPolicies.hpp:2695
fastdds::rtps::BuiltinAttributes builtin
Builtin parameters.
Definition QosPolicies.hpp:2680
rtps::ExternalLocators default_external_unicast_locators
The collection of external locators to use for communication on user created topics.
Definition QosPolicies.hpp:2700
bool ignore_non_matching_locators
Whether locators that don't match with the announced locators should be kept.
Definition QosPolicies.hpp:2705
virtual FASTDDS_EXPORTED_API ~WireProtocolConfigQos()=default
Destructor.
rtps::LocatorList default_unicast_locator_list
Default list of Unicast Locators to be used for any Endpoint defined inside this RTPSParticipant in t...
Definition QosPolicies.hpp:2689
fastdds::rtps::PortParameters port
Port Parameters.
Definition QosPolicies.hpp:2683
void clear() override
Clears the QosPolicy object.
Definition QosPolicies.hpp:2667
bool operator==(const WireProtocolConfigQos &b) const
Definition QosPolicies.hpp:2653
int32_t participant_id
Participant ID By default, -1.
Definition QosPolicies.hpp:2677
Qos Policy to configure the limit of the writer resources.
Definition QosPolicies.hpp:2832
virtual FASTDDS_EXPORTED_API ~WriterResourceLimitsQos()=default
Destructor.
bool operator==(const WriterResourceLimitsQos &b) const
Definition QosPolicies.hpp:2849
fastdds::ResourceLimitedContainerConfig reader_filters_allocation
Reader filters allocation limits.
Definition QosPolicies.hpp:2859
FASTDDS_EXPORTED_API WriterResourceLimitsQos()
Constructor.
Definition QosPolicies.hpp:2838
fastdds::ResourceLimitedContainerConfig matched_subscriber_allocation
Matched subscribers allocation limits.
Definition QosPolicies.hpp:2857
This class represents the union TypeIdentifier defined by the user in the IDL file.
Definition dds_xtypes_typeobject.hpp:2820
This class represents the structure TypeInformation defined by the user in the IDL file.
Definition dds_xtypes_typeobject.hpp:24606
Class xtypes::TypeInformationParameter.
Definition QosPolicies.hpp:2495
FASTDDS_EXPORTED_API TypeInformationParameter()
Constructor.
Definition QosPolicies.hpp:2504
virtual FASTDDS_EXPORTED_API ~TypeInformationParameter() override=default
Destructor.
eprosima::fastdds::dds::xtypes::TypeInformation type_information
Type Information.
Definition QosPolicies.hpp:2499
FASTDDS_EXPORTED_API bool assigned() const
Check if it is assigned.
Definition QosPolicies.hpp:2595
FASTDDS_EXPORTED_API TypeInformationParameter & operator=(const TypeInformationParameter &type)
Definition QosPolicies.hpp:2554
void clear() override
Clears the QosPolicy object.
Definition QosPolicies.hpp:2585
This class represents the union TypeObject defined by the user in the IDL file.
Definition dds_xtypes_typeobject.hpp:23463
Class BuiltinAttributes, to define the behavior of the RTPSParticipant builtin protocols.
Definition RTPSParticipantAttributes.hpp:350
Class LocatorList, a Locator vector that doesn't allow duplicates.
Definition LocatorList.hpp:97
Class PortParameters, to define the port parameters and gains related with the RTPS protocol.
Definition PortParameters.hpp:35
Definition PropertyPolicy.hpp:30
ParameterId_t
Enum for the unique parameter identifier.
Definition ParameterTypes.hpp:69
#define PARAMETER_TIME_LENGTH
Definition ParameterTypes.hpp:934
#define PARAMETER_BOOL_LENGTH
Definition ParameterTypes.hpp:776
@ PID_TOPIC_DATA
Definition ParameterTypes.hpp:77
@ PID_DURABILITY_SERVICE
Definition ParameterTypes.hpp:79
@ PID_LIVELINESS
Definition ParameterTypes.hpp:82
@ PID_OWNERSHIP
Definition ParameterTypes.hpp:88
@ PID_LATENCY_BUDGET
Definition ParameterTypes.hpp:81
@ PID_RESOURCE_LIMITS
Definition ParameterTypes.hpp:87
@ PID_DATASHARING
Definition ParameterTypes.hpp:172
@ PID_RELIABILITY
Definition ParameterTypes.hpp:83
@ PID_DURABILITY
Definition ParameterTypes.hpp:78
@ PID_USER_DATA
Definition ParameterTypes.hpp:73
@ PID_DEADLINE
Definition ParameterTypes.hpp:80
@ PID_TYPE_IDV1
Definition ParameterTypes.hpp:142
@ PID_TYPE_INFORMATION
Definition ParameterTypes.hpp:146
@ PID_DESTINATION_ORDER
Definition ParameterTypes.hpp:85
@ PID_PRESENTATION
Definition ParameterTypes.hpp:90
@ PID_LIFESPAN
Definition ParameterTypes.hpp:84
@ PID_DISABLE_POSITIVE_ACKS
Definition ParameterTypes.hpp:171
@ PID_TYPE_CONSISTENCY_ENFORCEMENT
Definition ParameterTypes.hpp:145
@ PID_OWNERSHIP_STRENGTH
Definition ParameterTypes.hpp:89
@ PID_PARTITION
Definition ParameterTypes.hpp:91
@ PID_TRANSPORT_PRIORITY
Definition ParameterTypes.hpp:93
@ PID_TIME_BASED_FILTER
Definition ParameterTypes.hpp:92
@ PID_GROUP_DATA
Definition ParameterTypes.hpp:76
@ PID_HISTORY
Definition ParameterTypes.hpp:86
@ PID_TYPE_OBJECTV1
Definition ParameterTypes.hpp:143
@ PID_DATA_REPRESENTATION
Definition ParameterTypes.hpp:144
Definition DomainParticipant.hpp:45
QosPolicyId_t
The identifier for each QosPolicy.
Definition QosPolicies.hpp:55
@ HISTORY_QOS_POLICY_ID
Definition QosPolicies.hpp:71
@ TIMEBASEDFILTER_QOS_POLICY_ID
Definition QosPolicies.hpp:67
@ TRANSPORTPRIORITY_QOS_POLICY_ID
Definition QosPolicies.hpp:78
@ RESOURCELIMITS_QOS_POLICY_ID
Definition QosPolicies.hpp:72
@ DATAREPRESENTATION_QOS_POLICY_ID
Definition QosPolicies.hpp:83
@ RELIABILITY_QOS_POLICY_ID
Definition QosPolicies.hpp:69
@ PUBLISHMODE_QOS_POLICY_ID
Definition QosPolicies.hpp:90
@ RTPSRELIABLEREADER_QOS_POLICY_ID
Definition QosPolicies.hpp:93
@ LATENCYBUDGET_QOS_POLICY_ID
Definition QosPolicies.hpp:63
@ NEXT_QOS_POLICY_ID
Definition QosPolicies.hpp:100
@ PRESENTATION_QOS_POLICY_ID
Definition QosPolicies.hpp:61
@ TYPECONSISTENCYENFORCEMENT_QOS_POLICY_ID
Definition QosPolicies.hpp:84
@ ENTITYFACTORY_QOS_POLICY_ID
Definition QosPolicies.hpp:73
@ TRANSPORTCONFIG_QOS_POLICY_ID
Definition QosPolicies.hpp:95
@ USERDATA_QOS_POLICY_ID
Definition QosPolicies.hpp:59
@ WRITERRESOURCELIMITS_QOS_POLICY_ID
Definition QosPolicies.hpp:98
@ WRITERDATALIFECYCLE_QOS_POLICY_ID
Definition QosPolicies.hpp:74
@ PARTITION_QOS_POLICY_ID
Definition QosPolicies.hpp:68
@ READERDATALIFECYCLE_QOS_POLICY_ID
Definition QosPolicies.hpp:75
@ RTPSENDPOINT_QOS_POLICY_ID
Definition QosPolicies.hpp:92
@ RTPSRELIABLEWRITER_QOS_POLICY_ID
Definition QosPolicies.hpp:94
@ DISABLEPOSITIVEACKS_QOS_POLICY_ID
Definition QosPolicies.hpp:87
@ PARTICIPANTRESOURCELIMITS_QOS_POLICY_ID
Definition QosPolicies.hpp:88
@ GROUPDATA_QOS_POLICY_ID
Definition QosPolicies.hpp:77
@ TYPECONSISTENCY_QOS_POLICY_ID
Definition QosPolicies.hpp:96
@ LIVELINESS_QOS_POLICY_ID
Definition QosPolicies.hpp:66
@ OWNERSHIP_QOS_POLICY_ID
Definition QosPolicies.hpp:64
@ OWNERSHIPSTRENGTH_QOS_POLICY_ID
Definition QosPolicies.hpp:65
@ LIFESPAN_QOS_POLICY_ID
Definition QosPolicies.hpp:79
@ READERRESOURCELIMITS_QOS_POLICY_ID
Definition QosPolicies.hpp:91
@ WIREPROTOCOLCONFIG_QOS_POLICY_ID
Definition QosPolicies.hpp:97
@ DEADLINE_QOS_POLICY_ID
Definition QosPolicies.hpp:62
@ TOPICDATA_QOS_POLICY_ID
Definition QosPolicies.hpp:76
@ DESTINATIONORDER_QOS_POLICY_ID
Definition QosPolicies.hpp:70
@ DURABILITYSERVICE_QOS_POLICY_ID
Definition QosPolicies.hpp:80
@ DURABILITY_QOS_POLICY_ID
Definition QosPolicies.hpp:60
@ INVALID_QOS_POLICY_ID
Definition QosPolicies.hpp:56
@ PROPERTYPOLICY_QOS_POLICY_ID
Definition QosPolicies.hpp:89
DataSharingKind
Data sharing configuration kinds.
Definition QosPolicies.hpp:2866
@ ON
Activate the use of DataSharing.
Definition QosPolicies.hpp:2876
@ OFF
Disable the use of DataSharing.
Definition QosPolicies.hpp:2880
@ AUTO
Automatic configuration.
Definition QosPolicies.hpp:2871
std::bitset< NEXT_QOS_POLICY_ID > PolicyMask
Definition QosPolicies.hpp:103
LivelinessQosPolicyKind
Enum LivelinessQosPolicyKind, different kinds of liveliness for LivelinessQosPolicy.
Definition QosPolicies.hpp:456
@ AUTOMATIC_LIVELINESS_QOS
The infrastructure will automatically signal liveliness for the DataWriters at least as often as requ...
Definition QosPolicies.hpp:460
@ MANUAL_BY_PARTICIPANT_LIVELINESS_QOS
The Service will assume that as long as at least one Entity within the DomainParticipant has asserted...
Definition QosPolicies.hpp:465
@ MANUAL_BY_TOPIC_LIVELINESS_QOS
The Service will only assume liveliness of the DataWriter if the application has asserted liveliness ...
Definition QosPolicies.hpp:469
const int32_t LENGTH_UNLIMITED
Definition Types.hpp:28
TypeConsistencyKind
Definition QosPolicies.hpp:2113
@ ALLOW_TYPE_COERCION
The DataWriter and the DataReader need not support the same data type in order for them to communicat...
Definition QosPolicies.hpp:2122
@ DISALLOW_TYPE_COERCION
The DataWriter and the DataReader must support the same data type in order for them to communicate.
Definition QosPolicies.hpp:2117
ReliabilityQosPolicyKind
Enum ReliabilityQosPolicyKind, different kinds of reliability for ReliabilityQosPolicy.
Definition QosPolicies.hpp:546
@ RELIABLE_RELIABILITY_QOS
Specifies the Service will attempt to deliver all samples in its history.
Definition QosPolicies.hpp:559
@ BEST_EFFORT_RELIABILITY_QOS
Indicates that it is acceptable to not retry propagation of any samples.
Definition QosPolicies.hpp:551
enum eprosima::fastdds::dds::DataRepresentationId DataRepresentationId_t
Enum DataRepresentationId, different kinds of topic data representation.
enum eprosima::fastdds::dds::DurabilityQosPolicyKind DurabilityQosPolicyKind_t
Enum DurabilityQosPolicyKind_t, different kinds of durability for DurabilityQosPolicy.
OwnershipQosPolicyKind
Enum OwnershipQosPolicyKind, different kinds of ownership for OwnershipQosPolicy.
Definition QosPolicies.hpp:629
@ SHARED_OWNERSHIP_QOS
Indicates shared ownership for each instance.
Definition QosPolicies.hpp:634
@ EXCLUSIVE_OWNERSHIP_QOS
Indicates each instance can only be owned by one DataWriter, but the owner of an instance can change ...
Definition QosPolicies.hpp:640
PublishModeQosPolicyKind
Enum PublishModeQosPolicyKind, different kinds of publication synchronism.
Definition QosPolicies.hpp:2009
@ ASYNCHRONOUS_PUBLISH_MODE
Asynchronous publication mode.
Definition QosPolicies.hpp:2011
@ SYNCHRONOUS_PUBLISH_MODE
Synchronous publication mode (default for writers).
Definition QosPolicies.hpp:2010
fastdds::rtps::RTPSParticipantAllocationAttributes ParticipantResourceLimitsQos
Holds allocation limits affecting collections managed by a participant.
Definition QosPolicies.hpp:2628
PresentationQosPolicyAccessScopeKind
Enum PresentationQosPolicyAccessScopeKind, different kinds of Presentation Policy order for Presentat...
Definition QosPolicies.hpp:1122
@ INSTANCE_PRESENTATION_QOS
Scope spans only a single instance.
Definition QosPolicies.hpp:1128
@ TOPIC_PRESENTATION_QOS
Scope spans to all instances within the same DataWriter (or DataReader), but not across instances in ...
Definition QosPolicies.hpp:1133
@ GROUP_PRESENTATION_QOS
Scope spans to all instances belonging to DataWriter (or DataReader) entities within the same Publish...
Definition QosPolicies.hpp:1137
constexpr DataRepresentationId_t DEFAULT_DATA_REPRESENTATION
Default DataRepresentationId used in Fast DDS.
Definition QosPolicies.hpp:2057
DurabilityQosPolicyKind
Enum DurabilityQosPolicyKind_t, different kinds of durability for DurabilityQosPolicy.
Definition QosPolicies.hpp:242
@ TRANSIENT_LOCAL_DURABILITY_QOS
For TRANSIENT_LOCAL, the service is only required to keep the data in the memory of the DataWriter th...
Definition QosPolicies.hpp:253
@ TRANSIENT_DURABILITY_QOS
For TRANSIENT, the service is only required to keep the data in memory and not in permanent storage; ...
Definition QosPolicies.hpp:258
@ PERSISTENT_DURABILITY_QOS
Data is kept on permanent storage, so that they can outlive a system session.
Definition QosPolicies.hpp:264
@ VOLATILE_DURABILITY_QOS
The Service does not need to keep any samples of data-instances on behalf of any DataReader that is n...
Definition QosPolicies.hpp:248
HistoryQosPolicyKind
Enum HistoryQosPolicyKind, different kinds of History Qos for HistoryQosPolicy.
Definition QosPolicies.hpp:1619
@ KEEP_LAST_HISTORY_QOS
On the publishing side, the Service will only attempt to keep the most recent “depth” samples of each...
Definition QosPolicies.hpp:1626
@ KEEP_ALL_HISTORY_QOS
On the publishing side, the Service will attempt to keep all samples (representing each value written...
Definition QosPolicies.hpp:1634
DestinationOrderQosPolicyKind
Enum DestinationOrderQosPolicyKind, different kinds of destination order for DestinationOrderQosPolic...
Definition QosPolicies.hpp:692
@ BY_SOURCE_TIMESTAMP_DESTINATIONORDER_QOS
Indicates that data is ordered based on a timestamp placed at the source (by the Service or by the ap...
Definition QosPolicies.hpp:703
@ BY_RECEPTION_TIMESTAMP_DESTINATIONORDER_QOS
Indicates that data is ordered based on the reception time at each Subscriber.
Definition QosPolicies.hpp:698
enum eprosima::fastdds::dds::PublishModeQosPolicyKind PublishModeQosPolicyKind_t
Enum PublishModeQosPolicyKind, different kinds of publication synchronism.
DataRepresentationId
Enum DataRepresentationId, different kinds of topic data representation.
Definition QosPolicies.hpp:2050
@ XCDR2_DATA_REPRESENTATION
Extended CDR Encoding version 2.
Definition QosPolicies.hpp:2053
@ XML_DATA_REPRESENTATION
XML Data Representation (Unsupported)
Definition QosPolicies.hpp:2052
@ XCDR_DATA_REPRESENTATION
Extended CDR Encoding version 1.
Definition QosPolicies.hpp:2051
unsigned char octet
Definition Types.hpp:83
FASTDDS_EXPORTED_API const char *const FASTDDS_FLOW_CONTROLLER_DEFAULT
Name of the default flow controller.
NetmaskFilterKind
Definition NetmaskFilterKind.hpp:31
enum eprosima::fastdds::rtps::MemoryManagementPolicy MemoryManagementPolicy_t
Enum MemoryuManagementPolicy_t, indicated the way memory is managed in terms of dealing with CacheCha...
@ PREALLOCATED_WITH_REALLOC_MEMORY_MODE
Default size preallocated, requires reallocation when a bigger message arrives.
Definition ResourceManagement.hpp:35
std::map< uint8_t, std::map< uint8_t, std::vector< LocatorWithMask > >, std::greater< uint8_t > > ExternalLocators
A collection of LocatorWithMask grouped by externality and cost.
Definition ExternalLocators.hpp:41
DurabilityKind_t
Durability kind.
Definition Types.hpp:56
@ TRANSIENT
Transient Durability.
Definition Types.hpp:59
@ TRANSIENT_LOCAL
Transient Local Durability.
Definition Types.hpp:58
@ PERSISTENT
NOT IMPLEMENTED.
Definition Types.hpp:60
@ VOLATILE
Volatile Durability.
Definition Types.hpp:57
eProsima namespace.
Definition EntityId_t.hpp:388
Specifies the configuration of a resource limited collection.
Definition ResourceLimitedContainerConfig.hpp:36
static ResourceLimitedContainerConfig dynamic_allocation_configuration(size_t increment=1u)
Return a resource limits configuration for a linearly growing, dynamically allocated collection.
Definition ResourceLimitedContainerConfig.hpp:71
static ResourceLimitedContainerConfig fixed_size_configuration(size_t size)
Return a resource limits configuration for a fixed size collection.
Definition ResourceLimitedContainerConfig.hpp:60
size_t maximum
Maximum number of elements allowed in the collection.
Definition ResourceLimitedContainerConfig.hpp:51
Structure Time_t, used to describe times at a DDS level.
Definition Time_t.hpp:36
Structure GuidPrefix_t, Guid Prefix of GUID_t.
Definition GuidPrefix_t.hpp:37
Holds allocation limits affecting collections managed by a participant.
Definition RTPSParticipantAllocationAttributes.hpp:129
Structure SerializedPayload_t.
Definition SerializedPayload.hpp:59
octet * data
Pointer to the data.
Definition SerializedPayload.hpp:68
bool copy(const SerializedPayload_t *serData, bool with_limit=true)
Copy another structure (including allocating new space for the data).
uint32_t max_size
Maximum size of the payload.
Definition SerializedPayload.hpp:70
uint32_t length
Actual length of the data.
Definition SerializedPayload.hpp:66
Struct ThreadSettings to specify various thread settings.
Definition ThreadSettings.hpp:37