20 #ifndef SUBSCRIBERHISTORY_H_
21 #define SUBSCRIBERHISTORY_H_
22 #ifndef DOXYGEN_SHOULD_SKIP_THIS_PUBLIC
24 #include <fastdds/dds/topic/TopicDataType.hpp>
25 #include <fastdds/rtps/resources/ResourceManagement.h>
26 #include <fastrtps/qos/ReaderQos.h>
27 #include <fastdds/rtps/history/ReaderHistory.h>
28 #include <fastrtps/qos/QosPolicies.h>
29 #include <fastrtps/common/KeyedChanges.h>
30 #include <fastrtps/subscriber/SampleInfo.h>
31 #include <fastrtps/attributes/TopicAttributes.h>
57 fastdds::dds::TopicDataType* type,
60 rtps::MemoryManagementPolicy_t mempolicy);
72 const_iterator removal,
73 bool release =
true)
override;
90 const rtps::GUID_t& writer_guid,
91 uint32_t total_payload_size,
92 size_t unknown_missing_changes_up_to,
93 bool& will_never_be_accepted)
const override;
103 rtps::CacheChange_t* change,
104 size_t unknown_missing_changes_up_to)
override;
113 rtps::CacheChange_t* change)
override;
126 std::chrono::steady_clock::time_point& max_blocking_time);
131 std::chrono::steady_clock::time_point& max_blocking_time);
148 rtps::CacheChange_t* change);
157 rtps::CacheChange_t* change,
167 const rtps::InstanceHandle_t& handle,
168 const std::chrono::steady_clock::time_point& next_deadline_us);
177 rtps::InstanceHandle_t& handle,
178 std::chrono::steady_clock::time_point& next_deadline_us);
182 using t_m_Inst_Caches = std::map<rtps::InstanceHandle_t, KeyedChanges>;
185 t_m_Inst_Caches keyed_changes_;
187 std::chrono::steady_clock::time_point next_deadline_us_;
195 fastdds::dds::TopicDataType* type_;
200 void* get_key_object_;
203 std::function<bool(rtps::CacheChange_t*,
size_t)> receive_fn_;
206 std::function<bool(rtps::CacheChange_t*)> complete_fn_;
215 rtps::CacheChange_t* a_change,
216 t_m_Inst_Caches::iterator& map_it);
224 bool find_key_for_change(
225 rtps::CacheChange_t* a_change,
226 t_m_Inst_Caches::iterator& map_it);
235 bool received_change_keep_all_no_key(
237 rtps::CacheChange_t* change,
238 size_t unknown_missing_changes_up_to);
240 bool received_change_keep_last_no_key(
241 rtps::CacheChange_t* change,
242 size_t unknown_missing_changes_up_to);
244 bool received_change_keep_all_with_key(
245 rtps::CacheChange_t* change,
246 size_t unknown_missing_changes_up_to);
248 bool received_change_keep_last_with_key(
249 rtps::CacheChange_t* change,
250 size_t unknown_missing_changes_up_to);
252 bool completed_change_keep_all_with_key(
253 rtps::CacheChange_t* change);
255 bool completed_change_keep_last_with_key(
256 rtps::CacheChange_t* change);
259 bool add_received_change(
260 rtps::CacheChange_t* a_change);
262 bool add_received_change_with_key(
263 rtps::CacheChange_t* a_change,
264 std::vector<rtps::CacheChange_t*>& instance_changes);
266 bool deserialize_change(
267 rtps::CacheChange_t* change,
268 uint32_t ownership_strength,
276 #endif // ifndef DOXYGEN_SHOULD_SKIP_THIS_PUBLIC