Enum Entry.ContextType
- java.lang.Object
-
- java.lang.Enum<Entry.ContextType>
-
- org.glassfish.contextpropagation.internal.Entry.ContextType
-
- All Implemented Interfaces:
Serializable
,Comparable<Entry.ContextType>
- Enclosing class:
- Entry
public static enum Entry.ContextType extends Enum<Entry.ContextType>
Identifies the type of a work context OPAQUE is a special type that identifies a context that came over the wire that could not be instantiated. Therefore it is opaque to the context propagation feature. However, opaque elements will be propagated even if this process cannot make sense of them since they may end up in a process that can understand them.
-
-
Enum Constant Summary
Enum Constants Enum Constant Description ASCII_STRING
ATOMICINTEGER
ATOMICLONG
BIGDECIMAL
BIGINTEGER
BOOLEAN
BYTE
CATALOG
CHAR
DOUBLE
FLOAT
INT
LONG
OPAQUE
SERIALIZABLE
SHORT
STRING
VIEW_CAPABLE
-
Method Summary
All Methods Static Methods Concrete Methods Modifier and Type Method Description static <T extends Number>
Entry.ContextTypefromNumberClass(Class<T> clz)
Utility method designed to quickly determine the context type corresponding to a given class, clz.static Entry.ContextType
fromOrdinal(int ordinal)
Get the ContextType corresponding to the specified ordinal value.static Entry.ContextType
valueOf(String name)
Returns the enum constant of this type with the specified name.static Entry.ContextType[]
values()
Returns an array containing the constants of this enum type, in the order they are declared.
-
-
-
Enum Constant Detail
-
ATOMICINTEGER
public static final Entry.ContextType ATOMICINTEGER
-
ATOMICLONG
public static final Entry.ContextType ATOMICLONG
-
ASCII_STRING
public static final Entry.ContextType ASCII_STRING
-
BIGDECIMAL
public static final Entry.ContextType BIGDECIMAL
-
BIGINTEGER
public static final Entry.ContextType BIGINTEGER
-
BOOLEAN
public static final Entry.ContextType BOOLEAN
-
BYTE
public static final Entry.ContextType BYTE
-
CATALOG
public static final Entry.ContextType CATALOG
-
CHAR
public static final Entry.ContextType CHAR
-
DOUBLE
public static final Entry.ContextType DOUBLE
-
FLOAT
public static final Entry.ContextType FLOAT
-
INT
public static final Entry.ContextType INT
-
LONG
public static final Entry.ContextType LONG
-
OPAQUE
public static final Entry.ContextType OPAQUE
-
SERIALIZABLE
public static final Entry.ContextType SERIALIZABLE
-
SHORT
public static final Entry.ContextType SHORT
-
STRING
public static final Entry.ContextType STRING
-
VIEW_CAPABLE
public static final Entry.ContextType VIEW_CAPABLE
-
-
Method Detail
-
values
public static Entry.ContextType[] 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 (Entry.ContextType c : Entry.ContextType.values()) System.out.println(c);
- Returns:
- an array containing the constants of this enum type, in the order they are declared
-
valueOf
public static Entry.ContextType 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
-
fromOrdinal
public static Entry.ContextType fromOrdinal(int ordinal)
Get the ContextType corresponding to the specified ordinal value. Mostly used by the WireAdapters- Parameters:
ordinal
-- Returns:
-
fromNumberClass
public static <T extends Number> Entry.ContextType fromNumberClass(Class<T> clz)
Utility method designed to quickly determine the context type corresponding to a given class, clz.- Parameters:
clz
-- Returns:
-
-