- java.lang.Object
-
- com.pervasive.datarush.types.EnumeratedValues
-
- All Implemented Interfaces:
Serializable
public final class EnumeratedValues extends Object implements Serializable
Deprecated.An unordered set of values defining an enumeration.- See Also:
- Serialized Form
-
-
Field Summary
Fields Modifier and Type Field Description static intNULL_ORDINALDeprecated.The ordinal value indicating a null value
-
Constructor Summary
Constructors Constructor Description EnumeratedValues(List<String> values)Deprecated.Defines a new enumeration.
-
Method Summary
All Methods Instance Methods Concrete Methods Deprecated Methods Modifier and Type Method Description booleanequals(Object o)Deprecated.intgetDefaultOrdinal()Deprecated.Returns the default value that is assumed for unspecified sparse data valuesintgetOrdinal(String value)Deprecated.Gets the ordinal value of the given enumeration value.StringgetValue(int ordinal)Deprecated.Gets the enumeration value specified by the given ordinal value.List<String>getValues()Deprecated.Gets the values in the enumeration.inthashCode()Deprecated.booleanisValidOrdinal(int ordinal)Deprecated.Indicates whether the given ordinal is valid for the enumeration.booleanisValidValue(String value)Deprecated.Indicates whether the given value is valid for the enumeration.intsize()Deprecated.Gets the number of values define in the enumeration.StringtoString()Deprecated.
-
-
-
Field Detail
-
NULL_ORDINAL
public static final int NULL_ORDINAL
Deprecated.The ordinal value indicating a null value- See Also:
- Constant Field Values
-
-
Constructor Detail
-
EnumeratedValues
public EnumeratedValues(List<String> values)
Deprecated.Defines a new enumeration. The order of the provided values will be preserved but, other than the first element, is insignificant. The first element is special since it represents the default value that is assumed for unspecified sparse values.- Parameters:
defaultValue- the default value that is assumed for unspecified sparse data valuesvalues- the values belonging to the enumeration- Throws:
IllegalArgumentException- if a value appears multiple times or if the default value is not in the specified list of values
-
-
Method Detail
-
getValues
public List<String> getValues()
Deprecated.Gets the values in the enumeration. These values will be returned in the same order that was specified upon creation. Note that order is insignificant for the purposes of comparisions ( comparisons will be based on the sorted string order ).- Returns:
- the values of the enumeration
-
size
public int size()
Deprecated.Gets the number of values define in the enumeration.- Returns:
- the count of enumeration values
-
isValidOrdinal
public boolean isValidOrdinal(int ordinal)
Deprecated.Indicates whether the given ordinal is valid for the enumeration.- Parameters:
ordinal- the ordinal value to test- Returns:
trueif the ordinal specifies a value in the enumeration,falseotherwise
-
getOrdinal
public int getOrdinal(String value)
Deprecated.Gets the ordinal value of the given enumeration value.- Parameters:
value- the value for which to obtain the ordinal value- Returns:
- the ordinal representing the enumeration value
- Throws:
IndexOutOfBoundsException- if the value is not valid for the enumeration
-
isValidValue
public boolean isValidValue(String value)
Deprecated.Indicates whether the given value is valid for the enumeration.- Parameters:
value- the value to test- Returns:
trueif the value is in the enumeration,falseotherwise
-
getValue
public String getValue(int ordinal)
Deprecated.Gets the enumeration value specified by the given ordinal value.- Parameters:
ordinal- the ordinal for which to obtain the value- Returns:
- the enumeration value represented by the ordinal
- Throws:
IndexOutOfBoundsException- if the ordinal is not valid for the enumeration
-
getDefaultOrdinal
public int getDefaultOrdinal()
Deprecated.Returns the default value that is assumed for unspecified sparse data values- Returns:
- the default value
-
-