Enum PollingType
-
- All Implemented Interfaces:
public enum PollingTypeEnumeration of polling service types for polling scheduling strategy.
These constants specify how a polling server handles jobs at each queue during a polling cycle:
- GATED - Serves only jobs present at the start of the polling cycle
- EXHAUSTIVE - Serves all jobs until the queue is empty
- KLIMITED - Serves at most K jobs per polling cycle
-
-
Field Summary
Fields Modifier and Type Field Description public final intvalue
-
Enum Constant Summary
Enum Constants Enum Constant Description GATEDEXHAUSTIVEKLIMITED
-
Method Summary
Modifier and Type Method Description static PollingTypefromValue(int value)Converts a numeric value to a PollingType enum value. static StringtoText(PollingType type)Converts a PollingType enum value to its text representation. static inttoId(PollingType type)Gets the ID (numeric value) of the polling type. static Array<PollingType>values()Returns an array containing the constants of this enum type, in the order they're declared. static PollingTypevalueOf(String name)Returns the enum constant of this type with the specified name. intgetValue()Gets the numeric value of this polling type. -
-
Method Detail
-
fromValue
static PollingType fromValue(int value)
Converts a numeric value to a PollingType enum value.
- Parameters:
value- the numeric value- Returns:
the corresponding PollingType enum value
-
toText
static String toText(PollingType type)
Converts a PollingType enum value to its text representation.
- Parameters:
type- the polling type to convert- Returns:
the text representation of the type
-
toId
static int toId(PollingType type)
Gets the ID (numeric value) of the polling type.
- Parameters:
type- the polling type- Returns:
the ID value
-
values
static Array<PollingType> values()
Returns an array containing the constants of this enum type, in the order they're declared. This method may be used to iterate over the constants.
- Returns:
an array containing the constants of this enum type, in the order they're declared
-
valueOf
static PollingType 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.)
- Returns:
the enum constant with the specified name
-
getValue
int getValue()
Gets the numeric value of this polling type.
- Returns:
the numeric value
-
-
-
-