public class EnumValues extends Object
| Constructor and Description |
|---|
EnumValues() |
| Modifier and Type | Method and Description |
|---|---|
static <E extends Enum<E>> |
getEnum(long value,
Class<E> enumClass)
Get the first enum item in enum class E which EnumValue value is equal to value
|
static <E extends Enum<E>> |
getEnumSet(long value,
Class<E> enumClass)
Get the set of all the enum item in enum class E which EnumValue value flags are all present in value
|
static <E extends Enum<?>> |
getValue(E enumItem)
Get the integer value associated with an enum item
|
static <E extends Enum<E>> |
getValue(EnumSet<E> set)
Get the integer value resulting from ORing all the values of all the enum items present in the enum set.
|
public EnumValues()
public static <E extends Enum<E>> E getEnum(long value, Class<E> enumClass)
E - type of the enumvalue - enumClass - public static <E extends Enum<E>> EnumSet<E> getEnumSet(long value, Class<E> enumClass)
E - type of the enumvalue - enumClass - public static <E extends Enum<?>> long getValue(E enumItem)
enumItem - EnumValuepublic static <E extends Enum<E>> long getValue(EnumSet<E> set)
set - the EnumSet to processgetValue(java.lang.Enum),
EnumValueCopyright © 2009-2015. All Rights Reserved.