Fast DDS  Version 3.1.2
Fast DDS
Loading...
Searching...
No Matches
RTPSMessageSenderInterface.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_RTPS_MESSAGES__RTPSMESSAGESENDERINTERFACE_HPP
21#define FASTDDS_RTPS_MESSAGES__RTPSMESSAGESENDERINTERFACE_HPP
22
23#ifndef DOXYGEN_SHOULD_SKIP_THIS_PUBLIC
24
25#include <chrono>
26#include <vector>
27
28#include <fastdds/rtps/common/Guid.hpp>
29#include <fastdds/rtps/transport/NetworkBuffer.hpp>
30
31namespace eprosima {
32namespace fastdds {
33namespace rtps {
34
35struct CDRMessage_t;
36
41{
42public:
43
44 virtual ~RTPSMessageSenderInterface() = default;
45
51 virtual bool destinations_have_changed() const = 0;
52
61
67 virtual const std::vector<GuidPrefix_t>& remote_participants() const = 0;
68
74 virtual const std::vector<GUID_t>& remote_guids() const = 0;
75
83 virtual bool send(
84 const std::vector<eprosima::fastdds::rtps::NetworkBuffer>& buffers,
85 const uint32_t& total_bytes,
86 std::chrono::steady_clock::time_point max_blocking_time_point) const = 0;
87
91 virtual void lock() = 0;
92
96 virtual void unlock() = 0;
97
98
99};
100
101} // namespace rtps
102} // namespace fastdds
103} // namespace eprosima
104
105#endif // ifndef DOXYGEN_SHOULD_SKIP_THIS_PUBLIC
106
107#endif // FASTDDS_RTPS_MESSAGES__RTPSMESSAGESENDERINTERFACE_HPP
Interface to handle destinations management and message sending.
Definition RTPSMessageSenderInterface.hpp:41
virtual bool destinations_have_changed() const =0
Check if the destinations managed by this sender interface have changed.
virtual const std::vector< GuidPrefix_t > & remote_participants() const =0
Get the GUID prefix of all the destination participants.
virtual bool send(const std::vector< eprosima::fastdds::rtps::NetworkBuffer > &buffers, const uint32_t &total_bytes, std::chrono::steady_clock::time_point max_blocking_time_point) const =0
Send a message through this interface.
virtual const std::vector< GUID_t > & remote_guids() const =0
Get the GUID of all destinations.
virtual GuidPrefix_t destination_guid_prefix() const =0
Get a GUID prefix representing all destinations.
eProsima namespace.
Structure GuidPrefix_t, Guid Prefix of GUID_t.
Definition GuidPrefix_t.hpp:37