19.2.11.1. RTPSWriter
-
class RTPSWriter : public eprosima::fastdds::rtps::Endpoint
Class RTPSWriter, manages the sending of data to the readers. Is always associated with a HistoryCache.
Public Functions
-
virtual bool matched_reader_add(const SubscriptionBuiltinTopicData &info) = 0
Add a matched reader represented by its attributes.
- Parameters:
info – Subscription info of the reader being matched.
- Returns:
True if added.
-
virtual bool matched_reader_remove(const GUID_t &reader_guid) = 0
Remove a matched reader.
- Parameters:
reader_guid – GUID of the reader to remove.
- Returns:
True if removed.
-
virtual bool matched_reader_is_matched(const GUID_t &reader_guid) = 0
Tells us if a specific Reader is matched against this writer.
- Parameters:
reader_guid – GUID of the reader to check.
- Returns:
True if it was matched.
-
virtual void reader_data_filter(IReaderDataFilter *filter) = 0
Set a content filter to perform content filtering on this writer.
This method sets a content filter that will be used to check whether a cache change is relevant for a reader or not.
- Parameters:
filter – The content filter to use on this writer. May be
nullptr
to remove the content filter (i.e. treat all samples as relevant).
-
virtual const IReaderDataFilter *reader_data_filter() const = 0
Get the content filter used to perform content filtering on this writer.
- Returns:
The content filter used on this writer.
-
virtual bool has_been_fully_delivered(const SequenceNumber_t &seq_num) const = 0
Check if a specific change has been delivered to the transport layer of every matched remote RTPSReader at least once.
- Parameters:
seq_num – Sequence number of the change to check.
- Returns:
true if delivered. False otherwise.
-
virtual bool is_acked_by_all(const SequenceNumber_t &seq_num) const = 0
Check if a specific change has been acknowledged by all Readers. Is only useful in reliable Writer. In BE Writers returns false when pending to be sent.
- Parameters:
seq_num – Sequence number to check.
- Returns:
True if acknowledged by all.
-
virtual bool wait_for_all_acked(const dds::Duration_t &max_wait) = 0
Waits until all changes were acknowledged or max_wait.
- Parameters:
max_wait – Maximum time to wait.
- Returns:
True if all were acknowledged.
-
virtual void update_attributes(const WriterAttributes &att) = 0
Update the Attributes of the Writer.
- Parameters:
att – New attributes
-
virtual WriterListener *get_listener() const = 0
Get listener
- Returns:
Listener
-
virtual bool set_listener(WriterListener *listener) = 0
Set the listener.
- Parameters:
listener – Pointer to the listener.
- Returns:
True if correctly set.
-
virtual bool is_async() const = 0
Get the publication mode
- Returns:
publication mode
-
virtual bool get_disable_positive_acks() const = 0
Returns if disable positive ACKs QoS is enabled.
- Returns:
Best effort writers always return false. Reliable writers override this method.
-
virtual bool matched_reader_add(const SubscriptionBuiltinTopicData &info) = 0