Class Query

java.lang.Object
filius.software.dns.Query

public class Query extends Object
* Question section format
The question section is used to carry the "question" in most queries, i.e., the parameters that define what is being asked. The section contains QDCOUNT (usually 1) entries, each of the following format: ...
  1. QNAME a domain name represented as a sequence of labels, where each label consists of a length octet followed by that number of octets. The domain name terminates with the zero length octet for the null label of the root. Note that this field may be an odd number of octets; no padding is used.
  2. QTYPE a two octet code which specifies the type of the query. The values for this field include all codes valid for a TYPE field, together with some more general codes which can match more than one type of RR.
  3. QCLASS a two octet code that specifies the class of the query. For example, the QCLASS field is IN for the Internet.
  • Constructor Details

    • Query

      public Query(String query)
      Ein Konstruktor, der aus einem String, der durch den Aufruf der Methode toString() erzeugt wurde, wieder eine Query erstellt.
      Parameters:
      nachricht - ein String, der durch die Methode toString() erstellt wurde
    • Query

      public Query(String qname, String qtype)
      Parameters:
      qname - a domain name
      qtype - a code which specifies the type of the query. Zur Belegung dieses Attributs sollten die entsprechenden Konstanten der Klasse ResourceRecord verwendet werden
  • Method Details

    • toString

      public String toString()
      Methode zum Abruf einer Anfrage (query). Das Rueckgabeformat ist NAME TYPE CLASS (Bsp.: web.de. A IN)
      Overrides:
      toString in class Object
    • holeDomainname

      public String holeDomainname()
    • holeTyp

      public String holeTyp()
    • holeKlasse

      public String holeKlasse()