Async 1.8.0
|
A class for representing a PTR DNS resource record. More...
#include <AsyncDnsResourceRecord.h>
Public Types | |
using | DName = std::string |
![]() | |
using | List |
The type for a list of resource records. | |
![]() | |
enum class | Type { ANY , A , PTR , CNAME , SRV , A , PTR , CNAME , SRV } |
The record type. More... | |
enum class | Class { IN , IN } |
The record class. More... | |
enum class | Type { ANY , A , PTR , CNAME , SRV , A , PTR , CNAME , SRV } |
enum class | Class { IN , IN } |
using | Name = std::string |
using | Ttl = uint32_t |
using | List = std::vector<std::unique_ptr<DnsResourceRecord>> |
The type for a list of resource records. | |
Public Member Functions | |
DnsResourceRecordPTR (const Name &name, Ttl ttl, const DName &dname="") | |
Constructor. | |
virtual bool | operator== (const DnsResourceRecordPTR &other) const |
Equality comparison operator. | |
virtual std::string | toString (void) const |
The string representation of this record. | |
void | setName (const DName &dname) |
Set the FQDN for this record. | |
const DName & | dname (void) const |
The FQDN for this record. | |
DnsResourceRecordPTR (const std::string &name, uint32_t ttl, const std::string &dname="") | |
~DnsResourceRecordPTR (void) | |
virtual const Type | type (void) const |
The type of record. | |
virtual std::string | toString (void) const |
The string representation of this record. | |
void | setName (const std::string &dname) |
const std::string & | dname (void) const |
![]() | |
DnsResourceRecordCRTP (const Name &name, Ttl ttl) | |
Constructor. | |
virtual DnsResourceRecord * | clone (void) const |
Clone this class. | |
virtual bool | operator== (const DnsResourceRecord &other) const |
Equality comparison operator. | |
![]() | |
DnsResourceRecord (const Name &name, Ttl ttl) | |
Constructor. | |
virtual | ~DnsResourceRecord (void) |
Destructor. | |
Class | classId (void) const |
The DNS class for the record. | |
const char * | classStr (void) const |
The DNS class for the record as a string. | |
const std::string & | typeStr (void) const |
The type of record as a string. | |
void | setName (const Name &name) |
Set the name for this record. | |
const Name & | name (void) const |
The name of this record. | |
void | setTtl (Ttl ttl) |
Set the TTL for this record. | |
Ttl | ttl (void) const |
The TTL for this record. | |
DnsResourceRecord (const std::string &name, uint32_t ttl) | |
Default constructor. | |
DnsResourceRecord (const DnsResourceRecord &)=delete | |
Disallow copy construction. | |
DnsResourceRecord & | operator= (const DnsResourceRecord &)=delete |
Disallow copy assignment. | |
virtual | ~DnsResourceRecord (void) |
Destructor. | |
Class | classId (void) const |
A_brief_member_function_description. | |
const char * | classStr (void) const |
const std::string & | typeStr (void) const |
void | setName (const std::string &name) |
const std::string & | name (void) const |
void | setTtl (uint32_t ttl) |
uint32_t | ttl (void) const |
Static Public Member Functions | |
static const Type | staticType (void) |
The type for this specific class. | |
static const Type | staticType (void) |
![]() | |
static const Type | staticType (void) |
The type for this specific class. | |
static const std::string & | typeToString (Type type) |
The type for this specific class represented as a string. | |
static const std::string & | typeToString (Type type) |
Additional Inherited Members | |
![]() | |
static constexpr Ttl | MAX_TTL = 0x7fffffff |
The maximum allowed value for a TTL. | |
A class for representing a PTR DNS resource record.
This class represents a PTR DNS resource record. One or more resource records is the result of performing a DNS query. This specific resource record maps an IP address to hostnames.
Definition at line 223 of file AsyncResourceRecord.h.
using Async::DnsResourceRecordPTR::DName = std::string |
Definition at line 414 of file AsyncDnsResourceRecord.h.
|
inline |
Constructor.
name | The name of this record |
ttl | The time-to-live, in seconds, for this record |
dname | The FQDN associaated with this record name |
Definition at line 427 of file AsyncDnsResourceRecord.h.
|
inline |
Definition at line 228 of file AsyncResourceRecord.h.
|
inline |
Definition at line 231 of file AsyncResourceRecord.h.
|
inline |
The FQDN for this record.
Definition at line 465 of file AsyncDnsResourceRecord.h.
Referenced by operator==(), setName(), setName(), and toString().
|
inline |
Definition at line 242 of file AsyncResourceRecord.h.
|
inlinevirtual |
Equality comparison operator.
other | The other resource record to comapare to |
NOTE: The TTL is not used in the comparison.
Implements Async::DnsResourceRecordCRTP< DnsResourceRecordPTR >.
Definition at line 438 of file AsyncDnsResourceRecord.h.
References dname(), and Async::DnsResourceRecord::operator==().
|
inline |
Set the FQDN for this record.
dname | The new FQDN for this record |
Definition at line 459 of file AsyncDnsResourceRecord.h.
References dname().
|
inline |
Definition at line 241 of file AsyncResourceRecord.h.
References dname().
|
inlinestatic |
The type for this specific class.
Definition at line 419 of file AsyncDnsResourceRecord.h.
References Async::DnsResourceRecord::PTR.
Referenced by type().
|
inlinestatic |
Definition at line 226 of file AsyncResourceRecord.h.
References Async::DnsResourceRecord::PTR.
|
inlinevirtual |
The string representation of this record.
Reimplemented from Async::DnsResourceRecord.
Definition at line 448 of file AsyncDnsResourceRecord.h.
References dname(), and Async::DnsResourceRecord::toString().
|
inlinevirtual |
The string representation of this record.
Reimplemented from Async::DnsResourceRecord.
Definition at line 234 of file AsyncResourceRecord.h.
References dname(), and Async::DnsResourceRecord::toString().
|
inlinevirtual |
The type of record.
Reimplemented from Async::DnsResourceRecordCRTP< DnsResourceRecordPTR >.
Definition at line 233 of file AsyncResourceRecord.h.
References staticType().