public interface DnsClient
Modifier and Type | Method and Description |
---|---|
DnsClient |
lookup(java.lang.String name,
Handler<AsyncResult<java.net.InetAddress>> handler)
Try to lookup the A (ipv4) or AAAA (ipv6) record for the given name.
|
DnsClient |
lookup4(java.lang.String name,
Handler<AsyncResult<java.net.Inet4Address>> handler)
Try to lookup the A (ipv4) record for the given name.
|
DnsClient |
lookup6(java.lang.String name,
Handler<AsyncResult<java.net.Inet6Address>> handler)
Try to lookup the AAAA (ipv6) record for the given name.
|
DnsClient |
resolveA(java.lang.String name,
Handler<AsyncResult<java.util.List<java.net.Inet4Address>>> handler)
Try to resolve all A (ipv4) records for the given name.
|
DnsClient |
resolveAAAA(java.lang.String name,
Handler<AsyncResult<java.util.List<java.net.Inet6Address>>> handler)
Try to resolve all AAAA (ipv6) records for the given name.
|
DnsClient |
resolveCNAME(java.lang.String name,
Handler<AsyncResult<java.util.List<java.lang.String>>> handler)
Try to resolve the CNAME record for the given name.
|
DnsClient |
resolveMX(java.lang.String name,
Handler<AsyncResult<java.util.List<MxRecord>>> handler)
Try to resolve the MX records for the given name.
|
DnsClient |
resolveNS(java.lang.String name,
Handler<AsyncResult<java.util.List<java.lang.String>>> handler)
Try to resolve the NS records for the given name.
|
DnsClient |
resolvePTR(java.lang.String name,
Handler<AsyncResult<java.lang.String>> handler)
Try to resolve the PTR record for the given name.
|
DnsClient |
resolveSRV(java.lang.String name,
Handler<AsyncResult<java.util.List<SrvRecord>>> handler)
Try to resolve the SRV records for the given name.
|
DnsClient |
resolveTXT(java.lang.String name,
Handler<AsyncResult<java.util.List<java.lang.String>>> handler)
Try to resolve the TXT records for the given name.
|
DnsClient |
reverseLookup(java.lang.String ipaddress,
Handler<AsyncResult<java.net.InetAddress>> handler)
Try to do a reverse lookup of an ipaddress.
|
DnsClient lookup(java.lang.String name, Handler<AsyncResult<java.net.InetAddress>> handler)
name
- The name to resolvehandler
- the Handler
to notify with the AsyncResult
. The AsyncResult
will get
notified with the resolved InetAddress
if a record was found. If non was found it will
get notifed with null
.
If an error accours it will get failed.DnsClient lookup4(java.lang.String name, Handler<AsyncResult<java.net.Inet4Address>> handler)
name
- The name to resolvehandler
- the Handler
to notify with the AsyncResult
. The AsyncResult
will get
notified with the resolved Inet4Address
if a record was found. If non was found it will
get notifed with null
.
If an error accours it will get failed.DnsClient lookup6(java.lang.String name, Handler<AsyncResult<java.net.Inet6Address>> handler)
name
- The name to resolvehandler
- the Handler
to notify with the AsyncResult
. The AsyncResult
will get
notified with the resolved Inet6Address
if a record was found. If non was found it will
get notifed with null
.
If an error accours it will get failed.DnsClient resolveA(java.lang.String name, Handler<AsyncResult<java.util.List<java.net.Inet4Address>>> handler)
name
- The name to resolvehandler
- the Handler
to notify with the AsyncResult
. The AsyncResult
will get
notified with a List
that contains all the resolved Inet4Address
es. If non was found
and empty List
will be used.
If an error accours it will get failed.DnsClient resolveAAAA(java.lang.String name, Handler<AsyncResult<java.util.List<java.net.Inet6Address>>> handler)
name
- The name to resolvehandler
- the Handler
to notify with the AsyncResult
. The AsyncResult
will get
notified with a List
that contains all the resolved Inet6Address
es. If non was found
and empty List
will be used.
If an error accours it will get failed.DnsClient resolveCNAME(java.lang.String name, Handler<AsyncResult<java.util.List<java.lang.String>>> handler)
name
- The name to resolve the CNAME forhandler
- the Handler
to notify with the AsyncResult
. The AsyncResult
will get
notified with the resolved String
if a record was found. If non was found it will
get notified with null
.
If an error accours it will get failed.DnsClient resolveMX(java.lang.String name, Handler<AsyncResult<java.util.List<MxRecord>>> handler)
name
- The name for which the MX records should be resolvedhandler
- the Handler
to notify with the AsyncResult
. The AsyncResult
will get
notified with a List that contains all resolved MxRecord
s, sorted by their
MxRecord.priority()
. If non was found it will get notified with an empty List
If an error accours it will get failed.DnsClient resolveTXT(java.lang.String name, Handler<AsyncResult<java.util.List<java.lang.String>>> handler)
name
- The name for which the TXT records should be resolvedhandler
- the Handler
to notify with the AsyncResult
. The AsyncResult
will get
notified with a List that contains all resolved String
s. If non was found it will
get notified with an empty List
If an error accours it will get failed.DnsClient resolvePTR(java.lang.String name, Handler<AsyncResult<java.lang.String>> handler)
name
- The name to resolve the PTR forhandler
- the Handler
to notify with the AsyncResult
. The AsyncResult
will get
notified with the resolved String
if a record was found. If non was found it will
get notified with null
.
If an error accours it will get failed.DnsClient resolveNS(java.lang.String name, Handler<AsyncResult<java.util.List<java.lang.String>>> handler)
name
- The name for which the NS records should be resolvedhandler
- the Handler
to notify with the AsyncResult
. The AsyncResult
will get
notified with a List that contains all resolved String
s. If non was found it will
get notified with an empty List
If an error accours it will get failed.DnsClient resolveSRV(java.lang.String name, Handler<AsyncResult<java.util.List<SrvRecord>>> handler)
name
- The name for which the SRV records should be resolvedhandler
- the Handler
to notify with the AsyncResult
. The AsyncResult
will get
notified with a List that contains all resolved SrvRecord
s. If non was found it will
get notified with an empty List
If an error accours it will get failed.DnsClient reverseLookup(java.lang.String ipaddress, Handler<AsyncResult<java.net.InetAddress>> handler)
ipaddress
- The ipaddress to resolve the PTR forhandler
- the Handler
to notify with the AsyncResult
. The AsyncResult
will get
notified with the resolved String
if a record was found. If non was found it will
get notified with null
.
If an error accours it will get failed.