Package org.cyclos.model
Enum Availability
- java.lang.Object
-
- java.lang.Enum<Availability>
-
- org.cyclos.model.Availability
-
- All Implemented Interfaces:
Serializable,Comparable<Availability>,HasMessageKey
public enum Availability extends Enum<Availability> implements HasMessageKey
Utility enum with the possible values regarding availability of some data.
-
-
Method Summary
All Methods Static Methods Instance Methods Concrete Methods Modifier and Type Method Description MessageKeygetMessageKey()static EnumMessageKeyResolver<Availability>resolverForConfirmationMethod()Returns a key resolver for operation/login confirmation method (password/device)static AvailabilityvalueOf(String name)Returns the enum constant of this type with the specified name.static Availability[]values()Returns an array containing the constants of this enum type, in the order they are declared.
-
-
-
Enum Constant Detail
-
OPTIONAL
public static final Availability OPTIONAL
The data is enabled and optional
-
REQUIRED
public static final Availability REQUIRED
The data is enabled and required
-
DISABLED
public static final Availability DISABLED
The data is disabled
-
-
Method Detail
-
values
public static Availability[] values()
Returns an array containing the constants of this enum type, in the order they are declared. This method may be used to iterate over the constants as follows:for (Availability c : Availability.values()) System.out.println(c);
- Returns:
- an array containing the constants of this enum type, in the order they are declared
-
valueOf
public static Availability valueOf(String name)
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
-
resolverForConfirmationMethod
public static EnumMessageKeyResolver<Availability> resolverForConfirmationMethod()
Returns a key resolver for operation/login confirmation method (password/device)- Returns:
-
getMessageKey
public MessageKey getMessageKey()
- Specified by:
getMessageKeyin interfaceHasMessageKey
-
-