QMdnsEngine  0.1.0
Multicast DNS library for Qt applications
Signals | Public Member Functions | List of all members
QMdnsEngine::Prober Class Reference

Prober to confirm that a record is unique More...

#include <qmdnsengine/prober.h>

Inheritance diagram for QMdnsEngine::Prober:

Signals

void nameConfirmed (const QByteArray &name)
 Indicate that the name has been confirmed unique. More...
 

Public Member Functions

 Prober (AbstractServer *server, const Record &record, QObject *parent=0)
 Create a new prober.
 

Detailed Description

Before responding to queries for a record, its uniqueness on the network must be confirmed. This class takes care of probing for existing records that match and adjusts the record's name until a unique one is found.

For example, to probe for a SRV record:

record.setName("My Service._http._tcp.local.");
record.setType(QMdnsEngine::SRV);
record.setPort(1234);
record.setTarget(hostname.hostname());
QMdnsEngine::Prober prober(&server, record);
connect(&prober, &QMdnsEngine::Prober::nameConfirmed, [](const QByteArray &name) {
qDebug() << "Name confirmed:" << name;
});

Member Function Documentation

§ nameConfirmed

void QMdnsEngine::Prober::nameConfirmed ( const QByteArray &  name)
signal
Parameters
namethat was confirmed to be unique

The documentation for this class was generated from the following file: