Interface DnsResponse

    • Method Detail

      • isAuthoritativeAnswer

        boolean isAuthoritativeAnswer()
        Returns true if responding server is authoritative for the domain name in the query message.
      • setAuthoritativeAnswer

        DnsResponse setAuthoritativeAnswer​(boolean authoritativeAnswer)
        Set to true if responding server is authoritative for the domain name in the query message.
        Parameters:
        authoritativeAnswer - flag for authoritative answer
      • isTruncated

        boolean isTruncated()
        Returns true if response has been truncated, usually if it is over 512 bytes.
      • setTruncated

        DnsResponse setTruncated​(boolean truncated)
        Set to true if response has been truncated (usually happens for responses over 512 bytes).
        Parameters:
        truncated - flag for truncation
      • isRecursionAvailable

        boolean isRecursionAvailable()
        Returns true if DNS server can handle recursive queries.
      • setRecursionAvailable

        DnsResponse setRecursionAvailable​(boolean recursionAvailable)
        Set to true if DNS server can handle recursive queries.
        Parameters:
        recursionAvailable - flag for recursion availability
      • setCode

        DnsResponse setCode​(DnsResponseCode code)
        Sets the response code for this message.
        Parameters:
        code - the response code
      • setRecursionDesired

        DnsResponse setRecursionDesired​(boolean recursionDesired)
        Description copied from interface: DnsMessage
        Sets the RD (recursion desired} field of this DNS message.
        Specified by:
        setRecursionDesired in interface DnsMessage
      • setZ

        DnsResponse setZ​(int z)
        Description copied from interface: DnsMessage
        Sets the Z (reserved for future use) field of this DNS message.
        Specified by:
        setZ in interface DnsMessage
      • touch

        DnsResponse touch​(Object hint)
        Description copied from interface: ReferenceCounted
        Records the current access location of this object with an additional arbitrary information for debugging purposes. If this object is determined to be leaked, the information recorded by this operation will be provided to you via ResourceLeakDetector.
        Specified by:
        touch in interface DnsMessage
        Specified by:
        touch in interface ReferenceCounted