T
- The builder type that is returned on terminal operationspublic interface BetweenBuilder<T>
This builder allows the specification of the upper bound of the between predicate. The left hand side expression of the between
predicate as well as the lower bound expression are already known to the builder and the methods of this builder either terminate the
building process or start a SubqueryInitiator
.
Modifier and Type | Method and Description |
---|---|
T |
and(Object end)
Constructs a between predicate with a parameter as upper bound.
|
T |
andExpression(String end)
Constructs a between predicate with an expression as upper bound.
|
SubqueryInitiator<T> |
andSubqery()
Constructs a between predicate with a subquery as upper bound.
|
SubqueryInitiator<T> |
andSubqery(String subqueryAlias,
String expression)
Constructs a between predicate with an expression containing a subquery as upper bound.
|
T and(Object end)
end
- The parameter for the upper boundT andExpression(String end)
end
- The upper bound expressionSubqueryInitiator<T> andSubqery()
SubqueryInitiator
for building the upper bound subquery.SubqueryInitiator<T> andSubqery(String subqueryAlias, String expression)
All occurrences of subqueryAlias
in expression
will be replaced by the subquery. This allows to build
expressions containing subqueries like following example shows:
andSubquery("x", "x * 2 + 1").from(Person.class, "p").select("COUNT(p)").end();
results in:
(SELECT COUNT(p) FROM Person p) * 2 + 1
subqueryAlias
- The alias for the subquery which will be replaced by the actual subqueryexpression
- The expression which will be used as left hand side of a predicate.
This expression contains the subqueryAlias
to define the insertion points for the subquery.SubqueryInitiator
for building the upper bound subquery.Copyright © 2015 Blazebit. All Rights Reserved.