org.jaffa.components.finder
Interface CriteriaField

All Known Implementing Classes:
BooleanCriteriaField, CurrencyCriteriaField, DateOnlyCriteriaField, DateTimeCriteriaField, DecimalCriteriaField, IntegerCriteriaField, RawCriteriaField, StringCriteriaField

public interface CriteriaField

This is the interface for all the Criteria fields. Each CriteriaField object will consist of an Operator and a array of values. The length of the array will be zero for the 'IsNull' and 'IsNotNull' operators. The length of the array will have to be >= 1, for the 'Between' and the 'In' operators. For all other operators, the length of the array will have to be one.

Author:
GautamJ

Field Summary
static String CONSECUTIVE_SEPARATORS
           
static String CONSECUTIVE_SEPARATORS_WITH_SPACE
           
static String RELATIONAL_BEGINS_WITH
          A global constant for the BEGINS_WITH criteria operator.
static String RELATIONAL_BETWEEN
          A global constant for the BETWEEN criteria operator.
static String RELATIONAL_ENDS_WITH
          A global constant for the ENDS_WITH criteria operator.
static String RELATIONAL_EQUALS
          A global constant for the EQUALS criteria operator.
static String RELATIONAL_GREATER_THAN
          A global constant for the GREATER_THAN criteria operator.
static String RELATIONAL_GREATER_THAN_EQUAL_TO
          A global constant for the GREATER_THAN_EQUAL_TO criteria operator.
static String RELATIONAL_IN
          A global constant for the IN criteria operator.
static String RELATIONAL_IS_NOT_NULL
          A global constant for the IS_NOT_NULL criteria operator.
static String RELATIONAL_IS_NULL
          A global constant for the IS_NULL criteria operator.
static String RELATIONAL_LIKE
          A global constant for the LIKE criteria operator.
static String RELATIONAL_NOT_EQUALS
          A global constant for the NOT_EQUALS criteria operator.
static String RELATIONAL_SMALLER_THAN
          A global constant for the SMALLER_THAN criteria operator.
static String RELATIONAL_SMALLER_THAN_EQUAL_TO
          A global constant for the SMALLER_THAN_EQUAL_TO criteria operator.
static char SEPARATOR_CHAR_FOR_IN_BETWEEN_OPERATORS
          This character should be used for separating the arguments for the In/Between relational operators.
static String SEPARATOR_FOR_IN_BETWEEN_OPERATORS
          This is the String representation of the constant SEPARATOR_CHAR_FOR_IN_BETWEEN_OPERATORS.
 
Method Summary
 String getOperator()
          Getter for property operator.
 Object[] returnValuesAsObjectArray()
          Getter for property values.
 

Field Detail

RELATIONAL_EQUALS

public static final String RELATIONAL_EQUALS
A global constant for the EQUALS criteria operator.

See Also:
Constant Field Values

RELATIONAL_NOT_EQUALS

public static final String RELATIONAL_NOT_EQUALS
A global constant for the NOT_EQUALS criteria operator.

See Also:
Constant Field Values

RELATIONAL_GREATER_THAN

public static final String RELATIONAL_GREATER_THAN
A global constant for the GREATER_THAN criteria operator.

See Also:
Constant Field Values

RELATIONAL_SMALLER_THAN

public static final String RELATIONAL_SMALLER_THAN
A global constant for the SMALLER_THAN criteria operator.

See Also:
Constant Field Values

RELATIONAL_GREATER_THAN_EQUAL_TO

public static final String RELATIONAL_GREATER_THAN_EQUAL_TO
A global constant for the GREATER_THAN_EQUAL_TO criteria operator.

See Also:
Constant Field Values

RELATIONAL_SMALLER_THAN_EQUAL_TO

public static final String RELATIONAL_SMALLER_THAN_EQUAL_TO
A global constant for the SMALLER_THAN_EQUAL_TO criteria operator.

See Also:
Constant Field Values

RELATIONAL_IS_NOT_NULL

public static final String RELATIONAL_IS_NOT_NULL
A global constant for the IS_NOT_NULL criteria operator.

See Also:
Constant Field Values

RELATIONAL_IS_NULL

public static final String RELATIONAL_IS_NULL
A global constant for the IS_NULL criteria operator.

See Also:
Constant Field Values

RELATIONAL_BEGINS_WITH

public static final String RELATIONAL_BEGINS_WITH
A global constant for the BEGINS_WITH criteria operator.

See Also:
Constant Field Values

RELATIONAL_ENDS_WITH

public static final String RELATIONAL_ENDS_WITH
A global constant for the ENDS_WITH criteria operator.

See Also:
Constant Field Values

RELATIONAL_LIKE

public static final String RELATIONAL_LIKE
A global constant for the LIKE criteria operator.

See Also:
Constant Field Values

RELATIONAL_BETWEEN

public static final String RELATIONAL_BETWEEN
A global constant for the BETWEEN criteria operator.

See Also:
Constant Field Values

RELATIONAL_IN

public static final String RELATIONAL_IN
A global constant for the IN criteria operator.

See Also:
Constant Field Values

SEPARATOR_CHAR_FOR_IN_BETWEEN_OPERATORS

public static final char SEPARATOR_CHAR_FOR_IN_BETWEEN_OPERATORS
This character should be used for separating the arguments for the In/Between relational operators.

See Also:
Constant Field Values

SEPARATOR_FOR_IN_BETWEEN_OPERATORS

public static final String SEPARATOR_FOR_IN_BETWEEN_OPERATORS
This is the String representation of the constant SEPARATOR_CHAR_FOR_IN_BETWEEN_OPERATORS.

See Also:
Constant Field Values

CONSECUTIVE_SEPARATORS

public static final String CONSECUTIVE_SEPARATORS
See Also:
Constant Field Values

CONSECUTIVE_SEPARATORS_WITH_SPACE

public static final String CONSECUTIVE_SEPARATORS_WITH_SPACE
See Also:
Constant Field Values
Method Detail

getOperator

public String getOperator()
Getter for property operator.

Returns:
Value of property operator.

returnValuesAsObjectArray

public Object[] returnValuesAsObjectArray()
Getter for property values. This method ensures that a class implementing the CriteriaField interface will have an array of criteria values. Additionally they are expected to have a 'getValues()' method returning actual instances. For eg. StringCriteriaField will have 'String[] getValues()', BooleanCriteriaField will have 'Boolean[] getValues()' and so on.

Returns:
An array of values for the Criteria.


Copyright © 2002-2004 JAFFA Project.