| Fast DDS Version 3.3.0 Fast DDS

Loading...
Searching...
No Matches
RTPSParticipantListener.hpp
1// Copyright 2016 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
18
19#ifndef FASTDDS_RTPS_PARTICIPANT__RTPSPARTICIPANTLISTENER_HPP
20#define FASTDDS_RTPS_PARTICIPANT__RTPSPARTICIPANTLISTENER_HPP
21
22#include <fastdds/rtps/builtin/data/PublicationBuiltinTopicData.hpp>
23#include <fastdds/rtps/builtin/data/SubscriptionBuiltinTopicData.hpp>
24#include <fastdds/rtps/builtin/data/ParticipantBuiltinTopicData.hpp>
25#include <fastdds/rtps/participant/ParticipantDiscoveryInfo.hpp>
26#include <fastdds/rtps/reader/ReaderDiscoveryStatus.hpp>
27#include <fastdds/rtps/writer/WriterDiscoveryStatus.hpp>
28
29 namespace eprosima {
30 namespace fastdds {
31 namespace rtps {
32
33 class RTPSParticipant;
34
39 class FASTDDS_EXPORTED_API RTPSParticipantListener
40{
41 public:
42
43 RTPSParticipantListener()
44 {
45 }
46
47 virtual ~RTPSParticipantListener()
48 {
49 }
50
60 virtual void on_participant_discovery(
61 RTPSParticipant* participant,
62 ParticipantDiscoveryStatus reason,
63 const ParticipantBuiltinTopicData& info,
64 bool& should_be_ignored)
65 {
66 static_cast<void>(participant);
67 static_cast<void>(reason);
68 static_cast<void>(info);
69
70 should_be_ignored = false;
71 }
72
73#if HAVE_SECURITY
74 virtual void onParticipantAuthentication(
75 RTPSParticipant* participant,
76 ParticipantAuthenticationInfo&& info)
77 {
78 static_cast<void>(participant);
79 static_cast<void>(info);
80 }
81
82#endif // if HAVE_SECURITY
83
93 virtual void on_reader_discovery(
94 RTPSParticipant* participant,
95 ReaderDiscoveryStatus reason,
96 const SubscriptionBuiltinTopicData& info,
97 bool& should_be_ignored)
98 {
99 static_cast<void>(participant);
100 static_cast<void>(reason);
101 static_cast<void>(info);
102 should_be_ignored = false;
103 }
104
114 virtual void on_writer_discovery(
115 RTPSParticipant* participant,
116 WriterDiscoveryStatus reason,
117 const PublicationBuiltinTopicData& info,
118 bool& should_be_ignored)
119 {
120 static_cast<void>(participant);
121 static_cast<void>(reason);
122 static_cast<void>(info);
123 should_be_ignored = false;
124 }
125
126};
127
128} // namespace rtps
129} // namespace fastdds
130} // namespace eprosima
131
132#endif //FASTDDS_RTPS_PARTICIPANT__RTPSPARTICIPANTLISTENER_HPP
eprosima::fastdds::rtps::RTPSParticipant
Class RTPSParticipant, contains the public API for a RTPSParticipant.
Definition RTPSParticipant.hpp:77
eprosima::fastdds::rtps::RTPSParticipantListener::on_reader_discovery
virtual void on_reader_discovery(RTPSParticipant *participant, ReaderDiscoveryStatus reason, const SubscriptionBuiltinTopicData &info, bool &should_be_ignored)
This method is called when a new Reader is discovered, or a previously discovered reader changes its ...
Definition RTPSParticipantListener.hpp:93
eprosima::fastdds::rtps::RTPSParticipantListener::RTPSParticipantListener
RTPSParticipantListener()
Definition RTPSParticipantListener.hpp:43
eprosima::fastdds::rtps::RTPSParticipantListener::on_writer_discovery
virtual void on_writer_discovery(RTPSParticipant *participant, WriterDiscoveryStatus reason, const PublicationBuiltinTopicData &info, bool &should_be_ignored)
This method is called when a new Writer is discovered, or a previously discovered writer changes its ...
Definition RTPSParticipantListener.hpp:114
eprosima::fastdds::rtps::RTPSParticipantListener::~RTPSParticipantListener
virtual ~RTPSParticipantListener()
Definition RTPSParticipantListener.hpp:47
eprosima::fastdds::rtps::RTPSParticipantListener::on_participant_discovery
virtual void on_participant_discovery(RTPSParticipant *participant, ParticipantDiscoveryStatus reason, const ParticipantBuiltinTopicData &info, bool &should_be_ignored)
This method is called when a new Participant is discovered, or a previously discovered participant ch...
Definition RTPSParticipantListener.hpp:60
eprosima::fastdds::rtps
Contains the RTPS protocol implementation.
eprosima::fastdds::rtps::WriterDiscoveryStatus
WriterDiscoveryStatus
Enum WriterDiscoveryStatus, four different status for discovered writers.
Definition WriterDiscoveryStatus.hpp:35
eprosima::fastdds::rtps::ParticipantDiscoveryStatus
ParticipantDiscoveryStatus
Enum ParticipantDiscoveryStatus, four different status for discovered participants.
Definition ParticipantDiscoveryInfo.hpp:37
eprosima::fastdds::rtps::ReaderDiscoveryStatus
ReaderDiscoveryStatus
Enum DISCOVERY_STATUS, four different status for discovered readers.
Definition ReaderDiscoveryStatus.hpp:36
eprosima::fastdds
eprosima
eProsima namespace.
eprosima::fastdds::rtps::ParticipantBuiltinTopicData
Definition ParticipantBuiltinTopicData.hpp:36
eprosima::fastdds::rtps::PublicationBuiltinTopicData
Structure PublicationBuiltinTopicData, contains the information on a discovered publication.
Definition PublicationBuiltinTopicData.hpp:48
eprosima::fastdds::rtps::SubscriptionBuiltinTopicData
Structure SubscriptionBuiltinTopicData, contains the information on a discovered subscription.
Definition SubscriptionBuiltinTopicData.hpp:47