Class NestedExpression

java.lang.Object
com.opensymphony.workflow.query.Expression
com.opensymphony.workflow.query.NestedExpression
All Implemented Interfaces:
Serializable

public class NestedExpression extends Expression
Nested expressions are used when constructing a workflow query. A nested expression consists of:
  • one or more expressions: Each of them can again be a NestedExpression.
  • operator: The operator used to evaluate the value of the nested expression from the specified sub expressions.
  • Author:
    Christine Zimmermann
    See Also:
    • Field Details

      • AND

        public static final int AND
        Constant to specify that all the expressions specified must evaluate to true for an item to be included in the search results.
        See Also:
      • OR

        public static final int OR
        Constant to specify that at least one of the expressions specified must evaluate to true for an item to be included in the search results.
        See Also:
    • Constructor Details

      • NestedExpression

        public NestedExpression()
      • NestedExpression

        public NestedExpression(Expression[] expressions, int operator)
        Create a NestedExpression that consists of multiple expressions.
        Parameters:
        expressions - an array of expressions for this query.
        operator - AND or OR.
    • Method Details

      • getExpression

        public Expression getExpression(int index)
      • getExpressionCount

        public int getExpressionCount()
        Get the number of expressions in this query.
      • setExpressionOperator

        public void setExpressionOperator(int expressionOperator)
      • getExpressionOperator

        public int getExpressionOperator()
        Returns:
        AND if all the expressions must match, or OR if only one must match.
      • setExpressions

        public void setExpressions(Expression[] expressions)
      • isNested

        public boolean isNested()
        Specified by:
        isNested in class Expression