Fast DDS  Version 3.6.1.0
Fast DDS
PublisherQos.hpp
1 // Copyright 2019 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_PUBLISHER_QOS__PUBLISHERQOS_HPP
21 #define FASTDDS_DDS_PUBLISHER_QOS__PUBLISHERQOS_HPP
22 
23 #include <fastdds/dds/core/policy/QosPolicies.hpp>
24 
25 namespace eprosima {
26 namespace fastdds {
27 namespace dds {
28 
39 {
40 public:
41 
45  FASTDDS_EXPORTED_API PublisherQos()
46  {
47  }
48 
52  FASTDDS_EXPORTED_API virtual ~PublisherQos() = default;
53 
55  const PublisherQos& b) const
56  {
57  return (this->presentation_ == b.presentation()) &&
58  (this->partition_ == b.partition()) &&
59  (this->group_data_ == b.group_data()) &&
60  (this->entity_factory_ == b.entity_factory());
61  }
62 
69  {
70  return presentation_;
71  }
72 
79  {
80  return presentation_;
81  }
82 
90  {
91  presentation_ = presentation;
92  }
93 
100  {
101  return partition_;
102  }
103 
110  {
111  return partition_;
112  }
113 
119  void partition(
121  {
122  partition_ = partition;
123  }
124 
130  const GroupDataQosPolicy& group_data() const
131  {
132  return group_data_;
133  }
134 
140  GroupDataQosPolicy& group_data()
141  {
142  return group_data_;
143  }
144 
151  const GroupDataQosPolicy& group_data)
152  {
153  group_data_ = group_data;
154  }
155 
162  {
163  return entity_factory_;
164  }
165 
172  {
173  return entity_factory_;
174  }
175 
183  {
184  entity_factory_ = entity_factory;
185  }
186 
187 private:
188 
190  PresentationQosPolicy presentation_;
191 
193  PartitionQosPolicy partition_;
194 
196  GroupDataQosPolicy group_data_;
197 
199  EntityFactoryQosPolicy entity_factory_;
200 
201 };
202 
203 FASTDDS_EXPORTED_API extern const PublisherQos PUBLISHER_QOS_DEFAULT;
204 
205 } // namespace dds
206 } // namespace fastdds
207 } // namespace eprosima
208 
209 #endif // FASTDDS_DDS_PUBLISHER_QOS__PUBLISHERQOS_HPP
Controls the behavior of the entity when acting as a factory for other entities.
Definition: QosPolicies.hpp:189
Set of strings that introduces a logical partition among the topics visible by the Publisher and Subs...
Definition: QosPolicies.hpp:1286
Specifies how the samples representing changes to data instances are presented to the subscribing app...
Definition: QosPolicies.hpp:1156
Class PublisherQos, containing all the possible Qos that can be set for a determined Publisher.
Definition: PublisherQos.hpp:39
bool operator==(const PublisherQos &b) const
Definition: PublisherQos.hpp:54
PartitionQosPolicy & partition()
Getter for PartitionQosPolicy.
Definition: PublisherQos.hpp:109
FASTDDS_EXPORTED_API PublisherQos()
Constructor.
Definition: PublisherQos.hpp:45
const PresentationQosPolicy & presentation() const
Getter for PresentationQosPolicy.
Definition: PublisherQos.hpp:68
const GroupDataQosPolicy & group_data() const
Getter for GroupDataQosPolicy.
Definition: PublisherQos.hpp:130
void group_data(const GroupDataQosPolicy &group_data)
Setter for GroupDataQosPolicy.
Definition: PublisherQos.hpp:150
virtual FASTDDS_EXPORTED_API ~PublisherQos()=default
Destructor.
void entity_factory(const EntityFactoryQosPolicy &entity_factory)
Setter for EntityFactoryQosPolicy.
Definition: PublisherQos.hpp:181
PresentationQosPolicy & presentation()
Getter for PresentationQosPolicy.
Definition: PublisherQos.hpp:78
const PartitionQosPolicy & partition() const
Getter for PartitionQosPolicy.
Definition: PublisherQos.hpp:99
const EntityFactoryQosPolicy & entity_factory() const
Getter for EntityFactoryQosPolicy.
Definition: PublisherQos.hpp:161
EntityFactoryQosPolicy & entity_factory()
Getter for EntityFactoryQosPolicy.
Definition: PublisherQos.hpp:171
GroupDataQosPolicy & group_data()
Getter for GroupDataQosPolicy.
Definition: PublisherQos.hpp:140
void presentation(const PresentationQosPolicy &presentation)
Setter for PresentationQosPolicy.
Definition: PublisherQos.hpp:88
void partition(const PartitionQosPolicy &partition)
Setter for PartitionQosPolicy.
Definition: PublisherQos.hpp:119
Definition: DomainParticipant.hpp:46
FASTDDS_EXPORTED_API const PublisherQos PUBLISHER_QOS_DEFAULT