public abstract class QueryBase<Q extends QueryBase<Q>> extends Object
Modifier and Type | Field and Description |
---|---|
static String |
MDC_PARAMETERS |
static String |
MDC_QUERY |
protected QueryMixin<Q> |
queryMixin |
Constructor and Description |
---|
QueryBase(QueryMixin<Q> queryMixin) |
Modifier and Type | Method and Description |
---|---|
Q |
distinct()
Set the Query to return distinct results
|
boolean |
equals(Object o) |
Q |
groupBy(Expression<?>... o)
Add grouping/aggregation expressions
|
Q |
groupBy(Expression<?> e)
Add a single grouping expression
|
int |
hashCode() |
Q |
having(Predicate... o)
Add filters for aggregation
|
Q |
having(Predicate e)
Add a single filter for aggregation
|
Q |
limit(long limit)
Defines the limit / max results for the query results
|
Q |
offset(long offset)
Defines the offset for the query results
|
Q |
orderBy(OrderSpecifier<?>... o)
Add order expressions
|
Q |
orderBy(OrderSpecifier<?> o)
Add a single order expression
|
Q |
restrict(QueryModifiers modifiers)
Defines both limit and offset of the query results
|
<P> Q |
set(ParamExpression<P> param,
P value)
Set the given parameter to the given value
|
String |
toString() |
Q |
where(Predicate... o)
Add the given filter conditions
|
Q |
where(Predicate o)
Add the given filter condition
|
public static final String MDC_QUERY
public static final String MDC_PARAMETERS
protected final QueryMixin<Q extends QueryBase<Q>> queryMixin
public QueryBase(QueryMixin<Q> queryMixin)
public Q distinct()
public Q groupBy(Expression<?> e)
e
- public Q groupBy(Expression<?>... o)
o
- public Q orderBy(OrderSpecifier<?> o)
o
- public Q orderBy(OrderSpecifier<?>... o)
o
- public Q where(Predicate o)
Skips null arguments
o
- filter conditions to be addedpublic Q where(Predicate... o)
Skips null arguments
o
- filter conditions to be addedpublic Q limit(@Nonnegative long limit)
limit
- public Q offset(long offset)
offset
- public Q restrict(QueryModifiers modifiers)
modifiers
- public <P> Q set(ParamExpression<P> param, P value)
P
- param
- value
- Copyright © 2007–2015 Mysema Ltd. All rights reserved.