|
||||||||||
| PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
| SUMMARY: NESTED | ENUM CONSTANTS | FIELD | METHOD | DETAIL: ENUM CONSTANTS | FIELD | METHOD | |||||||||

java.lang.Objectjava.lang.Enum<TestOperator>
net.sf.mpxj.TestOperator
public enum TestOperator
This class represents the set of operators used to perform a test between two or more operands.
| Method Summary | |
|---|---|
abstract boolean |
evaluate(java.lang.Object lhs,
java.lang.Object rhs)
This method applies the operator represented by this class to the supplied operands. |
protected int |
evaluateCompareTo(java.lang.Object lhs,
java.lang.Object rhs)
Implements a simple compare-to operation. |
protected boolean |
evaluateContains(java.lang.Object lhs,
java.lang.Object rhs)
Assuming the supplied arguments are both Strings, this method determines if rhs is contained within lhs. |
protected boolean |
evaluateContainsExactly(java.lang.Object lhs,
java.lang.Object rhs)
Assuming the supplied arguments are both Strings, this method determines if rhs is contained within lhs. |
protected boolean |
evaluateWithin(java.lang.Object lhs,
java.lang.Object rhs)
Determine if the supplied value falls within the specified range. |
static TestOperator |
getInstance(int type)
Retrieve an instance of the enum based on its int value. |
static TestOperator |
getInstance(java.lang.Number type)
Retrieve an instance of the enum based on its int value. |
protected java.lang.Object |
getSingleOperand(java.lang.Object operand)
This method is used to ensure that if a list of operand values has been supplied, that a single operand is extracted. |
int |
getValue()
Accessor method used to retrieve the numeric representation of the enum. |
static TestOperator |
valueOf(java.lang.String name)
Returns the enum constant of this type with the specified name. |
static TestOperator[] |
values()
Returns an array containing the constants of this enum type, in the order they are declared. |
| Methods inherited from class java.lang.Enum |
|---|
clone, compareTo, equals, finalize, getDeclaringClass, hashCode, name, ordinal, toString, valueOf |
| Methods inherited from class java.lang.Object |
|---|
getClass, notify, notifyAll, wait, wait, wait |
| Enum Constant Detail |
|---|
public static final TestOperator IS_ANY_VALUE
public static final TestOperator IS_WITHIN
public static final TestOperator IS_GREATER_THAN
public static final TestOperator IS_LESS_THAN
public static final TestOperator IS_GREATER_THAN_OR_EQUAL_TO
public static final TestOperator IS_LESS_THAN_OR_EQUAL_TO
public static final TestOperator EQUALS
public static final TestOperator DOES_NOT_EQUAL
public static final TestOperator CONTAINS
public static final TestOperator IS_NOT_WITHIN
public static final TestOperator DOES_NOT_CONTAIN
public static final TestOperator CONTAINS_EXACTLY
| Method Detail |
|---|
public static TestOperator[] values()
for (TestOperator c : TestOperator.values()) System.out.println(c);
public static TestOperator valueOf(java.lang.String name)
name - the name of the enum constant to be returned.
java.lang.IllegalArgumentException - if this enum type has no constant
with the specified name
java.lang.NullPointerException - if the argument is nullpublic static TestOperator getInstance(int type)
type - int type
public static TestOperator getInstance(java.lang.Number type)
type - int type
public int getValue()
getValue in interface MpxjEnum
public abstract boolean evaluate(java.lang.Object lhs,
java.lang.Object rhs)
lhs - operandrhs - operand
protected java.lang.Object getSingleOperand(java.lang.Object operand)
operand - operand value
protected boolean evaluateWithin(java.lang.Object lhs,
java.lang.Object rhs)
lhs - single value operandrhs - range operand
protected int evaluateCompareTo(java.lang.Object lhs,
java.lang.Object rhs)
lhs - operandrhs - operand
protected boolean evaluateContains(java.lang.Object lhs,
java.lang.Object rhs)
lhs - operandrhs - operand
protected boolean evaluateContainsExactly(java.lang.Object lhs,
java.lang.Object rhs)
lhs - operandrhs - operand
|
||||||||||
| PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
| SUMMARY: NESTED | ENUM CONSTANTS | FIELD | METHOD | DETAIL: ENUM CONSTANTS | FIELD | METHOD | |||||||||