Package com.boomi.connector.testutil
Class QueryGroupingBuilder
- java.lang.Object
-
- com.boomi.connector.testutil.QueryGroupingBuilder
-
public class QueryGroupingBuilder extends Object
Utility class for constructing aGroupingExpressionusing a simple "builder" style, for use withQueryFilterBuilder.
-
-
Constructor Summary
Constructors Constructor Description QueryGroupingBuilder(GroupingOperator operator)Constructs a QueryGroupingBuilder with the given initial operator.QueryGroupingBuilder(GroupingOperator operator, Object... nestedExprs)Constructs a QueryGroupingBuilder with the given initial operator and nested expressions.
-
Method Summary
All Methods Static Methods Instance Methods Concrete Methods Modifier and Type Method Description QueryGroupingBuilderaddExpressions(Object... nestedExprs)Adds some nested expressions to the expression.static QueryGroupingBuilderand(Object... nestedExprs)Returns a new QueryFilterBuilder with a grouping operator ofGroupingOperator.AND, and the given initial nested expressions (seeaddExpressions(java.lang.Object...)).static QueryGroupingBuilderor(Object... nestedExprs)Returns a new QueryFilterBuilder with a grouping operator ofGroupingOperator.OR, and the given initial nested expressions (seeaddExpressions(java.lang.Object...)).QueryGroupingBuildersetOperator(GroupingOperator operator)Sets the grouping operator for the expression.GroupingExpressiontoExpression()Returns the current state of this builder as a GroupingExpression.
-
-
-
Constructor Detail
-
QueryGroupingBuilder
public QueryGroupingBuilder(GroupingOperator operator)
Constructs a QueryGroupingBuilder with the given initial operator.- Parameters:
operator- the initial operator
-
QueryGroupingBuilder
public QueryGroupingBuilder(GroupingOperator operator, Object... nestedExprs)
Constructs a QueryGroupingBuilder with the given initial operator and nested expressions.- Parameters:
operator- the initial operatornestedExprs- the initial nested expressions, seeaddExpressions(java.lang.Object...)
-
-
Method Detail
-
setOperator
public QueryGroupingBuilder setOperator(GroupingOperator operator)
Sets the grouping operator for the expression.
-
addExpressions
public QueryGroupingBuilder addExpressions(Object... nestedExprs)
Adds some nested expressions to the expression. The given objects are converted to Expression instances usingQueryFilterBuilder.toExpression(java.lang.Object).
-
toExpression
public GroupingExpression toExpression()
Returns the current state of this builder as a GroupingExpression.
-
and
public static QueryGroupingBuilder and(Object... nestedExprs)
Returns a new QueryFilterBuilder with a grouping operator ofGroupingOperator.AND, and the given initial nested expressions (seeaddExpressions(java.lang.Object...)).
-
or
public static QueryGroupingBuilder or(Object... nestedExprs)
Returns a new QueryFilterBuilder with a grouping operator ofGroupingOperator.OR, and the given initial nested expressions (seeaddExpressions(java.lang.Object...)).
-
-