PcapPlusPlus
21.05
|
#include <DnsResourceData.h>
Public Member Functions | |
GenericDnsResourceData (uint8_t *dataPtr, size_t dataLen) | |
GenericDnsResourceData (const std::string &dataAsHexString) | |
GenericDnsResourceData (const GenericDnsResourceData &other) | |
bool | operator== (const GenericDnsResourceData &other) const |
std::string | toString () const |
bool | toByteArr (uint8_t *arr, size_t &arrLength, IDnsResource *dnsResource) const |
Public Member Functions inherited from pcpp::IDnsResourceData | |
virtual | ~IDnsResourceData () |
template<class IDnsResourceDataType > | |
bool | isTypeOf () const |
template<class IDnsResourceDataType > | |
IDnsResourceDataType * | castAs () |
A class that represents generic DNS RR data which cannot be represented in any of the other classes. It stores the DNS RR data as byte array
pcpp::GenericDnsResourceData::GenericDnsResourceData | ( | uint8_t * | dataPtr, |
size_t | dataLen | ||
) |
A c'tor for this class
[in] | dataPtr | A byte array that contains the raw data (as it written in the DNS packet). The data will be copied from this byte array to the object |
[in] | dataLen | The byte array size |
pcpp::GenericDnsResourceData::GenericDnsResourceData | ( | const std::string & | dataAsHexString | ) |
A c'tor for this class
[in] | dataAsHexString | A hex string that represents the DNS RR data |
pcpp::GenericDnsResourceData::GenericDnsResourceData | ( | const GenericDnsResourceData & | other | ) |
A copy c'tor for this class
[in] | other | The instance to copy from |
bool pcpp::GenericDnsResourceData::operator== | ( | const GenericDnsResourceData & | other | ) | const |
Equality operator overload for this class that compares the raw data stored in each object
[in] | other | The object to compare with |
|
virtual |
Convert the DNS RR data into a byte array
[out] | arr | A pointer to a pre-allocated byte array where the result will be written to |
[out] | arrLength | A reference to a 2-byte number where the result array length will be written to |
[in] | dnsResource | A pointer to a DNS resource object where this DNS RR data will be stored |
Implements pcpp::IDnsResourceData.
|
virtual |
Implements pcpp::IDnsResourceData.