Enum DNSState
- All Implemented Interfaces:
Serializable, Comparable<DNSState>
-
Nested Class Summary
Nested Classes -
Enum Constant Summary
Enum ConstantsEnum ConstantDescription -
Field Summary
Fields -
Constructor Summary
Constructors -
Method Summary
Modifier and TypeMethodDescriptionfinal DNSStateadvance()Returns the next advanced state.
In general, this advances one step in the following sequence: PROBING_1, PROBING_2, PROBING_3, ANNOUNCING_1, ANNOUNCING_2, ANNOUNCED.
or CANCELING_1, CANCELING_2, CANCELING_3, CANCELED Does not advance for ANNOUNCED and CANCELED state.final booleanReturns true, if this is an announced state.final booleanReturns true, if this is an announcing state.final booleanReturns true, if this is a canceled state.final booleanReturns true, if this is a canceling state.final booleanisClosed()Returns true, if this is a closing state.final booleanReturns true, if this is a closing state.final booleanReturns true, if this is a probing state.final DNSStaterevert()Returns to the next reverted state.final StringtoString()static DNSStateReturns the enum constant of this type with the specified name.static DNSState[]values()Returns an array containing the constants of this enum type, in the order they are declared.
-
Enum Constant Details
-
PROBING_1
-
PROBING_2
-
PROBING_3
-
ANNOUNCING_1
-
ANNOUNCING_2
-
ANNOUNCED
-
CANCELING_1
-
CANCELING_2
-
CANCELING_3
-
CANCELED
-
CLOSING
-
CLOSED
-
-
Field Details
-
_name
-
_state
-
-
Constructor Details
-
DNSState
-
-
Method Details
-
values
Returns an array containing the constants of this enum type, in the order they are declared.- Returns:
- an array containing the constants of this enum type, in the order they are declared
-
valueOf
Returns the enum constant of this type with the specified name. The string must match exactly an identifier used to declare an enum constant in this type. (Extraneous whitespace characters are not permitted.)- Parameters:
name- the name of the enum constant to be returned.- Returns:
- the enum constant with the specified name
- Throws:
IllegalArgumentException- if this enum type has no constant with the specified nameNullPointerException- if the argument is null
-
toString
-
advance
Returns the next advanced state.
In general, this advances one step in the following sequence: PROBING_1, PROBING_2, PROBING_3, ANNOUNCING_1, ANNOUNCING_2, ANNOUNCED.
or CANCELING_1, CANCELING_2, CANCELING_3, CANCELED Does not advance for ANNOUNCED and CANCELED state.- Returns:
- next state
-
revert
Returns to the next reverted state. All states except CANCELED revert to PROBING_1. Status CANCELED does not revert.- Returns:
- reverted state
-
isProbing
public final boolean isProbing()Returns true, if this is a probing state.- Returns:
trueif probing state,falseotherwise
-
isAnnouncing
public final boolean isAnnouncing()Returns true, if this is an announcing state.- Returns:
trueif announcing state,falseotherwise
-
isAnnounced
public final boolean isAnnounced()Returns true, if this is an announced state.- Returns:
trueif announced state,falseotherwise
-
isCanceling
public final boolean isCanceling()Returns true, if this is a canceling state.- Returns:
trueif canceling state,falseotherwise
-
isCanceled
public final boolean isCanceled()Returns true, if this is a canceled state.- Returns:
trueif canceled state,falseotherwise
-
isClosing
public final boolean isClosing()Returns true, if this is a closing state.- Returns:
trueif closing state,falseotherwise
-
isClosed
public final boolean isClosed()Returns true, if this is a closing state.- Returns:
trueif closed state,falseotherwise
-