Type (dnsjava documentation)
Date: 2013-04-10

org.xbill.DNS

## Class Type

- java.lang.Object
- - org.xbill.DNS.Type

-     public final class Type
      extends Object

  Constants and functions relating to DNS Types
  Author:
    Brian Wellington

- - ### Field Summary

    Fields
    Modifier and Type | Field and Description
    --- | ---
    `static int` | `A` Address
    `static int` | `A6` IPv6 address (experimental)
    `static int` | `AAAA` IPv6 address
    `static int` | `AFSDB` AFS cell database
    `static int` | `ANY` Matches any type
    `static int` | `APL` Address Prefix List
    `static int` | `ATMA` ATM address
    `static int` | `AXFR` Zone transfer
    `static int` | `CERT` Certificate
    `static int` | `CNAME` Canonical name (alias)
    `static int` | `DHCID` Dynamic Host Configuration Protocol (DHCP) ID
    `static int` | `DLV` DNSSEC Lookaside Validation, RFC 4431 .
    `static int` | `DNAME` Non-terminal name redirection
    `static int` | `DNSKEY` DNSSEC Key
    `static int` | `DS` Delegation Signer
    `static int` | `EID` Endpoint identifier
    `static int` | `GPOS` Geographical position (withdrawn)
    `static int` | `HINFO` Host information
    `static int` | `IPSECKEY` IPSEC key
    `static int` | `ISDN` ISDN calling address
    `static int` | `IXFR` Incremental zone transfer
    `static int` | `KEY` Key
    `static int` | `KX` Key exchange
    `static int` | `LOC` Location
    `static int` | `MAILA` Transfer mail agent records
    `static int` | `MAILB` Transfer mailbox records
    `static int` | `MB` Mailbox domain name
    `static int` | `MD` Mail destination
    `static int` | `MF` Mail forwarder
    `static int` | `MG` Mail group member
    `static int` | `MINFO` Mailbox information
    `static int` | `MR` Mail rename name
    `static int` | `MX` Mail routing information
    `static int` | `NAPTR` Naming authority pointer
    `static int` | `NIMLOC` Nimrod locator
    `static int` | `NS` Name server
    `static int` | `NSAP` NSAP address
    `static int` | `NSAP_PTR` Reverse NSAP address (deprecated)
    `static int` | `NSEC` Next Secure Name
    `static int` | `NSEC3` Next SECure, 3rd edition, RFC 5155
    `static int` | `NSEC3PARAM` Next SECure PARAMeter, RFC 5155
    `static int` | `NULL` Null record
    `static int` | `NXT` Next valid name in zone
    `static int` | `OPT` Options - contains EDNS metadata
    `static int` | `PTR` Domain name pointer
    `static int` | `PX` X.400 mail mapping
    `static int` | `RP` Responsible person
    `static int` | `RRSIG` Resource Record Signature
    `static int` | `RT` Router
    `static int` | `SIG` Signature
    `static int` | `SOA` Start of authority
    `static int` | `SPF` Sender Policy Framework (experimental)
    `static int` | `SRV` Server selection
    `static int` | `SSHFP` SSH Key Fingerprint
    `static int` | `TKEY` Transaction key - used to compute a shared secret or exchange a key
    `static int` | `TLSA` Transport Layer Security Authentication, draft-ietf-dane-protocol-23
    `static int` | `TSIG` Transaction signature
    `static int` | `TXT` Text strings
    `static int` | `WKS` Well known services
    `static int` | `X25` X.25 calling address

  - ### Method Summary

    Methods
    Modifier and Type | Method and Description
    --- | ---
    `static void` | `check(int val)` Checks that a numeric Type is valid.
    `static boolean` | `isRR(int type)` Is this type valid for a record (a non-meta type)?
    `static String` | `string(int val)` Converts a numeric Type into a String
    `static int` | `value(String s)` Converts a String representation of an Type into its numeric value
    `static int` | `value(String s, boolean numberok)` Converts a String representation of an Type into its numeric value.

    - ### Methods inherited from class java.lang.Object

      `clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait`

- - ### Field Detail

    - #### A

          public static final int A

      Address
      See Also:
        Constant Field Values

    - #### NS

          public static final int NS

      Name server
      See Also:
        Constant Field Values

    - #### MD

          public static final int MD

      Mail destination
      See Also:
        Constant Field Values

    - #### MF

          public static final int MF

      Mail forwarder
      See Also:
        Constant Field Values

    - #### CNAME

          public static final int CNAME

      Canonical name (alias)
      See Also:
        Constant Field Values

    - #### SOA

          public static final int SOA

      Start of authority
      See Also:
        Constant Field Values

    - #### MB

          public static final int MB

      Mailbox domain name
      See Also:
        Constant Field Values

    - #### MG

          public static final int MG

      Mail group member
      See Also:
        Constant Field Values

    - #### MR

          public static final int MR

      Mail rename name
      See Also:
        Constant Field Values

    - #### NULL

          public static final int NULL

      Null record
      See Also:
        Constant Field Values

    - #### WKS

          public static final int WKS

      Well known services
      See Also:
        Constant Field Values

    - #### PTR

          public static final int PTR

      Domain name pointer
      See Also:
        Constant Field Values

    - #### HINFO

          public static final int HINFO

      Host information
      See Also:
        Constant Field Values

    - #### MINFO

          public static final int MINFO

      Mailbox information
      See Also:
        Constant Field Values

    - #### MX

          public static final int MX

      Mail routing information
      See Also:
        Constant Field Values

    - #### TXT

          public static final int TXT

      Text strings
      See Also:
        Constant Field Values

    - #### RP

          public static final int RP

      Responsible person
      See Also:
        Constant Field Values

    - #### AFSDB

          public static final int AFSDB

      AFS cell database
      See Also:
        Constant Field Values

    - #### X25

          public static final int X25

      X.25 calling address
      See Also:
        Constant Field Values

    - #### ISDN

          public static final int ISDN

      ISDN calling address
      See Also:
        Constant Field Values

    - #### RT

          public static final int RT

      Router
      See Also:
        Constant Field Values

    - #### NSAP

          public static final int NSAP

      NSAP address
      See Also:
        Constant Field Values

    - #### NSAP_PTR

          public static final int NSAP_PTR

      Reverse NSAP address (deprecated)
      See Also:
        Constant Field Values

    - #### SIG

          public static final int SIG

      Signature
      See Also:
        Constant Field Values

    - #### KEY

          public static final int KEY

      Key
      See Also:
        Constant Field Values

    - #### PX

          public static final int PX

      X.400 mail mapping
      See Also:
        Constant Field Values

    - #### GPOS

          public static final int GPOS

      Geographical position (withdrawn)
      See Also:
        Constant Field Values

    - #### AAAA

          public static final int AAAA

      IPv6 address
      See Also:
        Constant Field Values

    - #### LOC

          public static final int LOC

      Location
      See Also:
        Constant Field Values

    - #### NXT

          public static final int NXT

      Next valid name in zone
      See Also:
        Constant Field Values

    - #### EID

          public static final int EID

      Endpoint identifier
      See Also:
        Constant Field Values

    - #### NIMLOC

          public static final int NIMLOC

      Nimrod locator
      See Also:
        Constant Field Values

    - #### SRV

          public static final int SRV

      Server selection
      See Also:
        Constant Field Values

    - #### ATMA

          public static final int ATMA

      ATM address
      See Also:
        Constant Field Values

    - #### NAPTR

          public static final int NAPTR

      Naming authority pointer
      See Also:
        Constant Field Values

    - #### KX

          public static final int KX

      Key exchange
      See Also:
        Constant Field Values

    - #### CERT

          public static final int CERT

      Certificate
      See Also:
        Constant Field Values

    - #### A6

          public static final int A6

      IPv6 address (experimental)
      See Also:
        Constant Field Values

    - #### DNAME

          public static final int DNAME

      Non-terminal name redirection
      See Also:
        Constant Field Values

    - #### OPT

          public static final int OPT

      Options - contains EDNS metadata
      See Also:
        Constant Field Values

    - #### APL

          public static final int APL

      Address Prefix List
      See Also:
        Constant Field Values

    - #### DS

          public static final int DS

      Delegation Signer
      See Also:
        Constant Field Values

    - #### SSHFP

          public static final int SSHFP

      SSH Key Fingerprint
      See Also:
        Constant Field Values

    - #### IPSECKEY

          public static final int IPSECKEY

      IPSEC key
      See Also:
        Constant Field Values

    - #### RRSIG

          public static final int RRSIG

      Resource Record Signature
      See Also:
        Constant Field Values

    - #### NSEC

          public static final int NSEC

      Next Secure Name
      See Also:
        Constant Field Values

    - #### DNSKEY

          public static final int DNSKEY

      DNSSEC Key
      See Also:
        Constant Field Values

    - #### DHCID

          public static final int DHCID

      Dynamic Host Configuration Protocol (DHCP) ID
      See Also:
        Constant Field Values

    - #### NSEC3

          public static final int NSEC3

      Next SECure, 3rd edition, RFC 5155
      See Also:
        Constant Field Values

    - #### NSEC3PARAM

          public static final int NSEC3PARAM

      Next SECure PARAMeter, RFC 5155
      See Also:
        Constant Field Values

    - #### TLSA

          public static final int TLSA

      Transport Layer Security Authentication, draft-ietf-dane-protocol-23
      See Also:
        Constant Field Values

    - #### SPF

          public static final int SPF

      Sender Policy Framework (experimental)
      See Also:
        Constant Field Values

    - #### TKEY

          public static final int TKEY

      Transaction key - used to compute a shared secret or exchange a key
      See Also:
        Constant Field Values

    - #### TSIG

          public static final int TSIG

      Transaction signature
      See Also:
        Constant Field Values

    - #### IXFR

          public static final int IXFR

      Incremental zone transfer
      See Also:
        Constant Field Values

    - #### AXFR

          public static final int AXFR

      Zone transfer
      See Also:
        Constant Field Values

    - #### MAILB

          public static final int MAILB

      Transfer mailbox records
      See Also:
        Constant Field Values

    - #### MAILA

          public static final int MAILA

      Transfer mail agent records
      See Also:
        Constant Field Values

    - #### ANY

          public static final int ANY

      Matches any type
      See Also:
        Constant Field Values

    - #### DLV

          public static final int DLV

      DNSSEC Lookaside Validation, RFC 4431 .
      See Also:
        Constant Field Values

  - ### Method Detail

    - #### check

          public static void check(int val)

      Checks that a numeric Type is valid.
      Throws:
        `InvalidTypeException` - The type is out of range.

    - #### string

          public static String string(int val)

      Converts a numeric Type into a String
      Parameters:
        `val` - The type value.
      Returns:
        The canonical string representation of the type
      Throws:
        `InvalidTypeException` - The type is out of range.

    - #### value

          public static int value(String s,
                  boolean numberok)

      Converts a String representation of an Type into its numeric value.
      Parameters:
        `s` - The string representation of the type
        `numberok` - Whether a number will be accepted or not.
      Returns:
        The type code, or -1 on error.

    - #### value

          public static int value(String s)

      Converts a String representation of an Type into its numeric value
      Returns:
        The type code, or -1 on error.

    - #### isRR

          public static boolean isRR(int type)

      Is this type valid for a record (a non-meta type)?