Package uk.num.numlib.dns
Interface DNSServices
-
- All Known Implementing Classes:
DNSServicesDefaultImpl
public interface DNSServicesThis interface defines the contract for the DNS Service provider.
-
-
Nested Class Summary
Nested Classes Modifier and Type Interface Description static classDNSServices.GetRecordResponse
-
Method Summary
All Methods Instance Methods Abstract Methods Modifier and Type Method Description DNSServices.GetRecordResponsegetRecordFromDnsNoCache(java.lang.String query, int timeoutMillis)Get a NUM record from DNS.java.lang.StringrebuildTXTRecordContent(org.xbill.DNS.Record[] records)Concatenate an array of TXT record values to a single String
-
-
-
Method Detail
-
rebuildTXTRecordContent
java.lang.String rebuildTXTRecordContent(org.xbill.DNS.Record[] records) throws RrSetNoHeadersException, RrSetHeaderFormatException, RrSetIncompleteExceptionConcatenate an array of TXT record values to a single String- Parameters:
records- The array of Records- Returns:
- The concatenated result.
- Throws:
RrSetNoHeadersException- on errorRrSetHeaderFormatException- on errorRrSetIncompleteException- on error
-
getRecordFromDnsNoCache
DNSServices.GetRecordResponse getRecordFromDnsNoCache(java.lang.String query, int timeoutMillis) throws NumInvalidDNSQueryException, NumNoRecordAvailableException
Get a NUM record from DNS.- Parameters:
query- The NUM formatted DNS query.timeoutMillis- The number of milliseconds to wait for a response.- Returns:
- A GetRecordResponse
- Throws:
NumInvalidDNSQueryException- on errorNumNoRecordAvailableException- if a CNAME or SPF record is received instead of a TXT record
-
-