- java.lang.Object
-
- java.lang.Enum<TokenOrder>
-
- com.pervasive.datarush.tokens.TokenOrder
-
- All Implemented Interfaces:
Serializable
,Comparable<TokenOrder>
public enum TokenOrder extends Enum<TokenOrder>
An ordering of token values.When ordering tokens, the null value is always considered the highest value.
-
-
Enum Constant Summary
Enum Constants Enum Constant Description ASCENDING
The ordering from lowest to highest value.DESCENDING
The ordering from highest to least value.
-
Method Summary
All Methods Static Methods Instance Methods Concrete Methods Modifier and Type Method Description int
getMultiplier()
Gets the multiplier associated with the ordering.String
getShortName()
Gets an abbreviated name for the ordering.static TokenOrder
valueOf(String name)
Returns the enum constant of this type with the specified name.static TokenOrder[]
values()
Returns an array containing the constants of this enum type, in the order they are declared.
-
-
-
Enum Constant Detail
-
ASCENDING
public static final TokenOrder ASCENDING
The ordering from lowest to highest value.
-
DESCENDING
public static final TokenOrder DESCENDING
The ordering from highest to least value.
-
-
Method Detail
-
values
public static TokenOrder[] 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 (TokenOrder c : TokenOrder.values()) System.out.println(c);
- Returns:
- an array containing the constants of this enum type, in the order they are declared
-
valueOf
public static TokenOrder 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
-
getShortName
public String getShortName()
Gets an abbreviated name for the ordering.- Returns:
- the abbreviated name.
-
getMultiplier
public int getMultiplier()
Gets the multiplier associated with the ordering. This is the value to apply to the results ofcompare()
to get the appropriate sign reflecting the ordering.- Returns:
- the ordering's multiplier.
-
-