Package com.tonic.analysis.query.value
Enum ValueKind
- java.lang.Object
-
- java.lang.Enum<ValueKind>
-
- com.tonic.analysis.query.value.ValueKind
-
- All Implemented Interfaces:
Serializable,Comparable<ValueKind>
public enum ValueKind extends Enum<ValueKind>
Discriminator forValuevariants, used by the comparator to dispatch without instanceof chains.
-
-
Enum Constant Summary
Enum Constants Enum Constant Description ABSENTNo value at all, such as an attribute the queried element does not carry; every comparison against it fails.BOOLA true or false flag, and the only kind a bare condition can be truth-tested on directly.INTA whole number, carried as a long.NULLAn explicit null literal, equal only to another null.REALA floating point number, carried as a double; compares numerically against INT.REGEXA compiled pattern, valid only on the right of a match operator.SETAn ordered list of member values, the only kind theinoperator accepts on its right.STRINGA text literal.TYPEA type reference, either an internal name or a descriptor; compared as text against STRING.
-
Method Summary
All Methods Static Methods Concrete Methods Modifier and Type Method Description static ValueKindvalueOf(String name)Returns the enum constant of this type with the specified name.static ValueKind[]values()Returns an array containing the constants of this enum type, in the order they are declared.
-
-
-
Enum Constant Detail
-
INT
public static final ValueKind INT
A whole number, carried as a long.
-
REAL
public static final ValueKind REAL
A floating point number, carried as a double; compares numerically against INT.
-
STRING
public static final ValueKind STRING
A text literal.
-
TYPE
public static final ValueKind TYPE
A type reference, either an internal name or a descriptor; compared as text against STRING.
-
BOOL
public static final ValueKind BOOL
A true or false flag, and the only kind a bare condition can be truth-tested on directly.
-
REGEX
public static final ValueKind REGEX
A compiled pattern, valid only on the right of a match operator.
-
SET
public static final ValueKind SET
An ordered list of member values, the only kind theinoperator accepts on its right.
-
NULL
public static final ValueKind NULL
An explicit null literal, equal only to another null.
-
ABSENT
public static final ValueKind ABSENT
No value at all, such as an attribute the queried element does not carry; every comparison against it fails.
-
-
Method Detail
-
values
public static ValueKind[] 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 (ValueKind c : ValueKind.values()) System.out.println(c);
- Returns:
- an array containing the constants of this enum type, in the order they are declared
-
valueOf
public static ValueKind 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
-
-