QMdnsEngine 0.2.1
Multicast DNS library for Qt applications
Loading...
Searching...
No Matches
QMdnsEngine::Query Class Reference

DNS query. More...

#include <qmdnsengine/query.h>

Public Member Functions

 Query ()
 Create an empty query.
 Query (const Query &other)
 Create a copy of an existing query.
virtual ~Query ()
 Destroy the query.
QByteArray name () const
 Retrieve the name being queried.
Queryoperator= (const Query &other)
 Assignment operator.
void setName (const QByteArray &name)
 Set the name to query.
void setType (quint16 type)
 Set the type of record to query.
void setUnicastResponse (bool unicastResponse)
 Set whether a unicast response is desired.
quint16 type () const
 Retrieve the type of record being queried.
bool unicastResponse () const
 Determine if a unicast response is desired.

Detailed Description

This class represents a query for a DNS record. For example, to query for the IPv4 address of a local host:

query.setName("myserver.local.");
query.setType(QMdnsEngine::A);
message.addQuery(query);
DNS query.
Definition query.h:52
void setName(const QByteArray &name)
Set the name to query.
void setType(quint16 type)
Set the type of record to query.

Member Function Documentation

◆ setType()

void QMdnsEngine::Query::setType ( quint16 type)

Constants, such as QMdnsEngine::SRV are provided for convenience.


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