Search in sources :

Example 1 with DnsQueryResult

use of org.minidns.dnsqueryresult.DnsQueryResult in project Smack by igniterealtime.

the class DnsOverXmppMiniDnsResolver method resolve.

@Override
public DnsMessage resolve(DnsMessage query) throws IOException {
    Question question = query.getQuestion();
    final DnsQueryResult dnsQueryResult;
    if (query.isDnssecOk()) {
        DnssecQueryResult dnssecQueryResult = dnssecClient.queryDnssec(question);
        dnsQueryResult = dnssecQueryResult.dnsQueryResult;
    } else {
        dnsQueryResult = dnsClient.query(question);
    }
    return dnsQueryResult.response;
}
Also used : DnsQueryResult(org.minidns.dnsqueryresult.DnsQueryResult) DnssecQueryResult(org.minidns.dnssec.DnssecQueryResult) Question(org.minidns.dnsmessage.Question)

Aggregations

Question (org.minidns.dnsmessage.Question)1 DnsQueryResult (org.minidns.dnsqueryresult.DnsQueryResult)1 DnssecQueryResult (org.minidns.dnssec.DnssecQueryResult)1