public class DefaultQueryMetadata extends java.lang.Object implements QueryMetadata, java.lang.Cloneable
QueryMetadata
interfaceConstructor and Description |
---|
DefaultQueryMetadata()
Create an empty DefaultQueryMetadata instance
|
Modifier and Type | Method and Description |
---|---|
void |
addFlag(QueryFlag flag) |
void |
addGroupBy(Expression<?> o)
Add the given group by expressions
|
void |
addHaving(Predicate e)
Add the given having expressions
|
void |
addJoin(JoinType joinType,
Expression<?> expr)
Add the given query join
|
void |
addJoinCondition(Predicate o)
Add the given join condition to the last given join
|
void |
addJoinFlag(JoinFlag flag)
Add the given join flag to the last given join
|
void |
addOrderBy(OrderSpecifier<?> o)
Add the given order specifiers
|
void |
addProjection(Expression<?> o)
Add the given projections
|
void |
addWhere(Predicate e)
Add the given where expressions
|
void |
clearOrderBy()
Clear the order expressions
|
void |
clearProjection()
Clear the projection
|
void |
clearWhere()
Clear the where expressions
|
QueryMetadata |
clone()
Clone this QueryMetadata instance
|
boolean |
equals(java.lang.Object o) |
java.util.Set<QueryFlag> |
getFlags() |
java.util.List<Expression<?>> |
getGroupBy()
Get the group by expressions
|
Predicate |
getHaving()
Get the having expressions
|
java.util.List<JoinExpression> |
getJoins()
Get the query joins
|
QueryModifiers |
getModifiers()
Get the QueryModifiers
|
java.util.List<OrderSpecifier<?>> |
getOrderBy()
Get the OrderSpecifiers
|
java.util.Map<ParamExpression<?>,java.lang.Object> |
getParams()
Get the parameters
|
java.util.List<Expression<?>> |
getProjection()
Get the projection
|
Predicate |
getWhere()
Get the expressions aggregated into a single boolean expression or null,
if none where defined
|
boolean |
hasFlag(QueryFlag flag) |
int |
hashCode() |
boolean |
isDistinct()
Get whether the projection is distinct
|
boolean |
isUnique()
Get whether the projection is unique
|
DefaultQueryMetadata |
noValidate()
Disable validation
|
void |
reset()
Reset the projection
|
void |
setDistinct(boolean distinct) |
void |
setLimit(java.lang.Long limit) |
void |
setModifiers(QueryModifiers restriction) |
void |
setOffset(java.lang.Long offset) |
<T> void |
setParam(ParamExpression<T> param,
T value) |
void |
setUnique(boolean unique) |
void |
setValidate(boolean v) |
public DefaultQueryMetadata()
public DefaultQueryMetadata noValidate()
public void addFlag(QueryFlag flag)
addFlag
in interface QueryMetadata
public void addJoinFlag(JoinFlag flag)
QueryMetadata
addJoinFlag
in interface QueryMetadata
public void addGroupBy(Expression<?> o)
QueryMetadata
addGroupBy
in interface QueryMetadata
public void addHaving(Predicate e)
QueryMetadata
addHaving
in interface QueryMetadata
public void addJoin(JoinType joinType, Expression<?> expr)
QueryMetadata
addJoin
in interface QueryMetadata
public void addJoinCondition(Predicate o)
QueryMetadata
addJoinCondition
in interface QueryMetadata
public void addOrderBy(OrderSpecifier<?> o)
QueryMetadata
addOrderBy
in interface QueryMetadata
public void addProjection(Expression<?> o)
QueryMetadata
addProjection
in interface QueryMetadata
public void addWhere(Predicate e)
QueryMetadata
addWhere
in interface QueryMetadata
public void clearOrderBy()
QueryMetadata
clearOrderBy
in interface QueryMetadata
public void clearProjection()
QueryMetadata
clearProjection
in interface QueryMetadata
public void clearWhere()
QueryMetadata
clearWhere
in interface QueryMetadata
public QueryMetadata clone()
QueryMetadata
clone
in interface QueryMetadata
clone
in class java.lang.Object
public java.util.List<Expression<?>> getGroupBy()
QueryMetadata
getGroupBy
in interface QueryMetadata
public Predicate getHaving()
QueryMetadata
getHaving
in interface QueryMetadata
public java.util.List<JoinExpression> getJoins()
QueryMetadata
getJoins
in interface QueryMetadata
@Nullable public QueryModifiers getModifiers()
QueryMetadata
getModifiers
in interface QueryMetadata
public java.util.Map<ParamExpression<?>,java.lang.Object> getParams()
QueryMetadata
getParams
in interface QueryMetadata
public java.util.List<OrderSpecifier<?>> getOrderBy()
QueryMetadata
getOrderBy
in interface QueryMetadata
public java.util.List<Expression<?>> getProjection()
QueryMetadata
getProjection
in interface QueryMetadata
public Predicate getWhere()
QueryMetadata
getWhere
in interface QueryMetadata
public boolean isDistinct()
QueryMetadata
isDistinct
in interface QueryMetadata
public boolean isUnique()
QueryMetadata
isUnique
in interface QueryMetadata
public void reset()
QueryMetadata
reset
in interface QueryMetadata
public void setDistinct(boolean distinct)
setDistinct
in interface QueryMetadata
public void setLimit(java.lang.Long limit)
setLimit
in interface QueryMetadata
public void setModifiers(@Nullable QueryModifiers restriction)
setModifiers
in interface QueryMetadata
public void setOffset(java.lang.Long offset)
setOffset
in interface QueryMetadata
public void setUnique(boolean unique)
setUnique
in interface QueryMetadata
public <T> void setParam(ParamExpression<T> param, T value)
setParam
in interface QueryMetadata
public java.util.Set<QueryFlag> getFlags()
getFlags
in interface QueryMetadata
public boolean hasFlag(QueryFlag flag)
hasFlag
in interface QueryMetadata
public void setValidate(boolean v)
setValidate
in interface QueryMetadata
public boolean equals(java.lang.Object o)
equals
in class java.lang.Object
public int hashCode()
hashCode
in class java.lang.Object
Copyright © 2007-2013 Mysema Ltd. All Rights Reserved.