Package org.xcsp.common
Enum Types.TypeConditionOperatorRel
- java.lang.Object
-
- java.lang.Enum<Types.TypeConditionOperatorRel>
-
- org.xcsp.common.Types.TypeConditionOperatorRel
-
- All Implemented Interfaces:
Serializable
,Comparable<Types.TypeConditionOperatorRel>
- Enclosing class:
- Types
public static enum Types.TypeConditionOperatorRel extends Enum<Types.TypeConditionOperatorRel>
The enum type specifying the different types of relational operators that can be used in conditions.
-
-
Method Summary
All Methods Static Methods Instance Methods Concrete Methods Modifier and Type Method Description Types.TypeConditionOperatorRel
arithmeticInversion()
Returns the operator that is the reverse operator of this operator (no change for NE and EQ).boolean
isValidFor(long v1, long v2)
Returns true iff this operator evaluates to true when given the two specified operands.boolean
oneOf(Types.TypeConditionOperatorRel... types)
Types.TypeExpr
toExpr()
The type fromTypeExpr
with the same name as this type, if it exists,null
otherwise.static Types.TypeConditionOperatorRel
valueFor(String s)
static Types.TypeConditionOperatorRel
valueOf(String name)
Returns the enum constant of this type with the specified name.static Types.TypeConditionOperatorRel[]
values()
Returns an array containing the constants of this enum type, in the order they are declared.
-
-
-
Enum Constant Detail
-
LT
public static final Types.TypeConditionOperatorRel LT
-
LE
public static final Types.TypeConditionOperatorRel LE
-
GE
public static final Types.TypeConditionOperatorRel GE
-
GT
public static final Types.TypeConditionOperatorRel GT
-
NE
public static final Types.TypeConditionOperatorRel NE
-
EQ
public static final Types.TypeConditionOperatorRel EQ
-
-
Method Detail
-
values
public static Types.TypeConditionOperatorRel[] 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 (Types.TypeConditionOperatorRel c : Types.TypeConditionOperatorRel.values()) System.out.println(c);
- Returns:
- an array containing the constants of this enum type, in the order they are declared
-
valueOf
public static Types.TypeConditionOperatorRel 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
-
arithmeticInversion
public Types.TypeConditionOperatorRel arithmeticInversion()
Returns the operator that is the reverse operator of this operator (no change for NE and EQ).
-
isValidFor
public boolean isValidFor(long v1, long v2)
Returns true iff this operator evaluates to true when given the two specified operands.
-
valueFor
public static Types.TypeConditionOperatorRel valueFor(String s)
-
oneOf
public boolean oneOf(Types.TypeConditionOperatorRel... types)
-
toExpr
public Types.TypeExpr toExpr()
The type fromTypeExpr
with the same name as this type, if it exists,null
otherwise.- Returns:
- The type from
TypeExpr
with the same name as this type, if it exists,null
otherwise
-
-