Class PublisherListener, allows the end user to implement callbacks triggered by certain events.
using namespace eprosima::pubsub;
using namespace eprosima::rtps;
{
public:
RTPSParticipant* p;
RTPSParticipantAttributes Pparam;
eprosima::dds::Publisher* pub;
PublisherAttributes Pubparam;
TestTypeListener()
{
p = DomainRTPSParticipant::createRTPSParticipant(Pparam);
}
~TestTypeListener()
{
}
void onHistoryFull()
{
pub->removeMinSeqCache();
}
Publisher* pub,
MatchingInfo& info)
{
if (info.status == MATCHED_MATCHING)
{
cout << "Discovery!" << endl;
}
else if (info.status == REMOVED_MATCHING)
{
cout << "Subscription removed" << endl;
}
}
};
virtual void onPublicationMatched(Publisher *pub, rtps::MatchingInfo &info)
This method is called when the Publisher is matched (or unmatched) against an endpoint.
Definition: PublisherListener.h:53
PublisherListener()
Definition: PublisherListener.h:40