@UnstableApi public class DnsResponseCode extends java.lang.Object implements java.lang.Comparable<DnsResponseCode>
RCODE
, as defined in RFC2929.Modifier and Type | Field and Description |
---|---|
static DnsResponseCode |
BADALG
The 'BADALG' DNS RCODE (21), as defined in RFC2930.
|
static DnsResponseCode |
BADKEY
The 'BADKEY' DNS RCODE (17), as defined in RFC2845.
|
static DnsResponseCode |
BADMODE
The 'BADMODE' DNS RCODE (19), as defined in RFC2930.
|
static DnsResponseCode |
BADNAME
The 'BADNAME' DNS RCODE (20), as defined in RFC2930.
|
static DnsResponseCode |
BADTIME
The 'BADTIME' DNS RCODE (18), as defined in RFC2845.
|
static DnsResponseCode |
BADVERS_OR_BADSIG
|
private int |
code |
static DnsResponseCode |
FORMERR
The 'FormErr' DNS RCODE (1), as defined in RFC1035.
|
private java.lang.String |
name |
static DnsResponseCode |
NOERROR
The 'NoError' DNS RCODE (0), as defined in RFC1035.
|
static DnsResponseCode |
NOTAUTH
The 'NotAuth' DNS RCODE (9), as defined in RFC2136.
|
static DnsResponseCode |
NOTIMP
The 'NotImp' DNS RCODE (4), as defined in RFC1035.
|
static DnsResponseCode |
NOTZONE
The 'NotZone' DNS RCODE (10), as defined in RFC2136.
|
static DnsResponseCode |
NXDOMAIN
The 'NXDomain' DNS RCODE (3), as defined in RFC1035.
|
static DnsResponseCode |
NXRRSET
The 'NXRRSet' DNS RCODE (8), as defined in RFC2136.
|
static DnsResponseCode |
REFUSED
The 'Refused' DNS RCODE (5), as defined in RFC1035.
|
static DnsResponseCode |
SERVFAIL
The 'ServFail' DNS RCODE (2), as defined in RFC1035.
|
private java.lang.String |
text |
static DnsResponseCode |
YXDOMAIN
The 'YXDomain' DNS RCODE (6), as defined in RFC2136.
|
static DnsResponseCode |
YXRRSET
The 'YXRRSet' DNS RCODE (7), as defined in RFC2136.
|
Modifier | Constructor and Description |
---|---|
private |
DnsResponseCode(int code) |
|
DnsResponseCode(int code,
java.lang.String name) |
Modifier and Type | Method and Description |
---|---|
int |
compareTo(DnsResponseCode o) |
boolean |
equals(java.lang.Object o)
Equality of
DnsResponseCode only depends on intValue() . |
int |
hashCode() |
int |
intValue()
Returns the error code for this
DnsResponseCode . |
java.lang.String |
toString()
Returns a formatted error message for this
DnsResponseCode . |
static DnsResponseCode |
valueOf(int responseCode)
Returns the
DnsResponseCode that corresponds with the given responseCode . |
public static final DnsResponseCode NOERROR
public static final DnsResponseCode FORMERR
public static final DnsResponseCode SERVFAIL
public static final DnsResponseCode NXDOMAIN
public static final DnsResponseCode NOTIMP
public static final DnsResponseCode REFUSED
public static final DnsResponseCode YXDOMAIN
public static final DnsResponseCode YXRRSET
public static final DnsResponseCode NXRRSET
public static final DnsResponseCode NOTAUTH
public static final DnsResponseCode NOTZONE
public static final DnsResponseCode BADVERS_OR_BADSIG
public static final DnsResponseCode BADKEY
public static final DnsResponseCode BADTIME
public static final DnsResponseCode BADMODE
public static final DnsResponseCode BADNAME
public static final DnsResponseCode BADALG
private final int code
private final java.lang.String name
private java.lang.String text
private DnsResponseCode(int code)
public DnsResponseCode(int code, java.lang.String name)
public static DnsResponseCode valueOf(int responseCode)
DnsResponseCode
that corresponds with the given responseCode
.responseCode
- the DNS RCODEDnsResponseCode
public int intValue()
DnsResponseCode
.public int compareTo(DnsResponseCode o)
compareTo
in interface java.lang.Comparable<DnsResponseCode>
public int hashCode()
hashCode
in class java.lang.Object
public boolean equals(java.lang.Object o)
DnsResponseCode
only depends on intValue()
.equals
in class java.lang.Object
public java.lang.String toString()
DnsResponseCode
.toString
in class java.lang.Object