Package io.netty.resolver.dns
Class DnsAddressDecoder
java.lang.Object
io.netty.resolver.dns.DnsAddressDecoder
Decodes an
InetAddress
from an A or AAAA DnsRawRecord
.-
Field Summary
Fields -
Constructor Summary
Constructors -
Method Summary
Modifier and TypeMethodDescription(package private) static InetAddress
decodeAddress
(DnsRecord record, String name, boolean decodeIdn) Decodes anInetAddress
from an A or AAAADnsRawRecord
.
-
Field Details
-
INADDRSZ4
private static final int INADDRSZ4- See Also:
-
INADDRSZ6
private static final int INADDRSZ6- See Also:
-
-
Constructor Details
-
DnsAddressDecoder
private DnsAddressDecoder()
-
-
Method Details
-
decodeAddress
Decodes anInetAddress
from an A or AAAADnsRawRecord
.- Parameters:
record
- theDnsRecord
, most likely aDnsRawRecord
name
- the host name of the decoded addressdecodeIdn
- whether to convertname
to a unicode host name- Returns:
- the
InetAddress
, ornull
ifrecord
is not aDnsRawRecord
or its content is malformed
-