18#ifndef FASTDDS_RTPS_COMMON__WRITEPARAMS_HPP
19#define FASTDDS_RTPS_COMMON__WRITEPARAMS_HPP
23#include <fastdds/rtps/common/OriginalWriterInfo.hpp>
24#include <fastdds/rtps/common/SampleIdentity.hpp>
25#include <fastdds/rtps/common/Time_t.hpp>
65 sample_identity_ = sample_id;
79 sample_identity_ = std::move(sample_id);
90 return sample_identity_;
100 return sample_identity_;
113 related_sample_identity_ = sample_id;
127 related_sample_identity_ = std::move(sample_id);
138 return related_sample_identity_;
148 return related_sample_identity_;
158 return source_timestamp_;
168 return source_timestamp_;
181 source_timestamp_ = timestamp;
195 source_timestamp_ = std::move(timestamp);
206 return user_write_data_;
217 std::shared_ptr<UserWriteData> write_data)
219 user_write_data_ = write_data;
225 return has_more_replies_;
231 has_more_replies_ = more_replies;
241 return original_writer_info_;
250 return original_writer_info_;
263 original_writer_info_ = original_writer;
287 class FASTDDS_EXPORTED_API UserWriteDataPtr :
public std::shared_ptr<UserWriteData>
292 std::shared_ptr<UserWriteData> ptr)
293 :
std::shared_ptr<UserWriteData>(ptr)
300 SampleIdentity sample_identity_;
302 SampleIdentity related_sample_identity_;
304 Time_t source_timestamp_{ -1, TIME_T_INFINITE_NANOSECONDS };
306 UserWriteDataPtr user_write_data_{
nullptr};
308 bool has_more_replies_ =
false;
310 OriginalWriterInfo original_writer_info_;
Definition OriginalWriterInfo.hpp:31
This class is used to specify a sample.
Definition SampleIdentity.hpp:34
Structure Time_t, used to describe times at RTPS protocol.
Definition Time_t.hpp:38
This class contains additional information of a CacheChange.
Definition WriteParams.hpp:37
WriteParams & user_write_data(std::shared_ptr< UserWriteData > write_data)
Set the user write data.
Definition WriteParams.hpp:216
SampleIdentity & sample_identity()
Set the value of the sample_identity member.
Definition WriteParams.hpp:98
SampleIdentity & related_sample_identity()
Set the value of the related_sample_identity member.
Definition WriteParams.hpp:146
const OriginalWriterInfo & original_writer_info() const
Get the Original Writer Info.
Definition WriteParams.hpp:239
WriteParams & source_timestamp(const Time_t ×tamp)
Set the source_timestamp member of this class.
Definition WriteParams.hpp:178
WriteParams & sample_identity(const SampleIdentity &sample_id)
Set the value of the sample_identity member.
Definition WriteParams.hpp:62
WriteParams & original_writer_info(const OriginalWriterInfo &original_writer)
Set the Original Writer Info of the original writer.
Definition WriteParams.hpp:260
static WriteParams write_params_default() noexcept
Default value for methods receiving a WriteParams.
Definition WriteParams.hpp:280
WriteParams & has_more_replies(bool more_replies)
Definition WriteParams.hpp:228
Time_t & source_timestamp()
Set the value of the source_timestamp member.
Definition WriteParams.hpp:166
const SampleIdentity & related_sample_identity() const
Get the value of the related_sample_identity member.
Definition WriteParams.hpp:136
bool has_more_replies() const
Definition WriteParams.hpp:223
std::shared_ptr< UserWriteData > user_write_data() const
Retrieves the user write data.
Definition WriteParams.hpp:204
const SampleIdentity & sample_identity() const
Get the value of the sample_identity member.
Definition WriteParams.hpp:88
Time_t source_timestamp() const
Get the value of the source_timestamp member.
Definition WriteParams.hpp:156
WriteParams & related_sample_identity(SampleIdentity &&sample_id)
Set the related_sample_identity member of this class.
Definition WriteParams.hpp:124
WriteParams & sample_identity(SampleIdentity &&sample_id)
Set the value of the sample_identity member.
Definition WriteParams.hpp:76
WriteParams & related_sample_identity(const SampleIdentity &sample_id)
Set the value of the related_sample_identity member of this class.
Definition WriteParams.hpp:110
OriginalWriterInfo & original_writer_info()
Get the Original Writer Info.
Definition WriteParams.hpp:248
static WriteParams WRITE_PARAM_DEFAULT
Definition WriteParams.hpp:267
WriteParams & source_timestamp(Time_t &×tamp)
Set the source_timestamp member of this class.
Definition WriteParams.hpp:192
Contains the RTPS protocol implementation.
Definition EntityId_t.hpp:388
virtual ~UserWriteData()=default