20.1.2.4. DomainParticipantListener

class DomainParticipantListener : public eprosima::fastdds::dds::PublisherListener, public eprosima::fastdds::dds::SubscriberListener, public eprosima::fastdds::dds::TopicListener

Class DomainParticipantListener, overrides behaviour towards certain events.

Public Functions

inline DomainParticipantListener()

Constructor.

inline virtual ~DomainParticipantListener()

Destructor.

inline virtual void on_participant_discovery(DomainParticipant *participant, fastdds::rtps::ParticipantDiscoveryStatus reason, const ParticipantBuiltinTopicData &info, bool &should_be_ignored)

This method is called when a new Participant is discovered, or a previously discovered participant changes its QOS or is removed.

Parameters:
  • participant[out] Pointer to the Participant which discovered the remote participant.

  • reason[out] Reason of the change in the status of the discovered participant.

  • info[out] Remote participant information. User can take ownership of the object.

  • should_be_ignored[out] Flag to indicate the library to automatically ignore the discovered Participant.

inline virtual void onParticipantAuthentication(DomainParticipant *participant, rtps::ParticipantAuthenticationInfo &&info)

This method is called when a new Participant is authenticated.

Parameters:
  • participant[out] Pointer to the authenticated Participant.

  • info[out] Remote participant authentication information. User can take ownership of the object.

inline virtual void on_data_reader_discovery(DomainParticipant *participant, rtps::ReaderDiscoveryStatus reason, const SubscriptionBuiltinTopicData &info, bool &should_be_ignored)

This method is called when a new DataReader is discovered, or a previously discovered DataReader changes its QOS or is removed.

Parameters:
  • participant[in] Pointer to the Participant which discovered the remote reader.

  • reason[in] The reason motivating this method to be called.

  • info[in] Remote reader information.

  • should_be_ignored[out] Flag to indicate the library to automatically ignore the discovered reader.

inline virtual void on_data_writer_discovery(DomainParticipant *participant, rtps::WriterDiscoveryStatus reason, const PublicationBuiltinTopicData &info, bool &should_be_ignored)

This method is called when a new DataWriter is discovered, or a previously discovered DataWriter changes its QOS or is removed.

Parameters:
  • participant[in] Pointer to the Participant which discovered the remote writer.

  • reason[in] The reason motivating this method to be called.

  • info[in] Remote writer information.

  • should_be_ignored[out] Flag to indicate the library to automatically ignore the discovered writer.