AbstractQuery interface defines functionality that is common
to both top-level queries and subqueries.
It is not intended to be used directly in query construction.
All queries must have: a set of root entities (which may in turn own joins).
All queries may have: a conjunction of restrictions.
| Modifier and Type | Method and Description |
|---|---|
| public AbstractQuery | Returns: the modified queryboolean value specifying whether duplicate
results must be eliminated from the query result or
whether they must be retained distinct)Specify whether duplicate query results are eliminated. |
| public <X> Root | |
| public <X> Root | Returns: query root corresponding to the given entitymetamodel entity representing the entity
of type X entity)Create and add a query root corresponding to the given entity, forming a cartesian product with any existing roots. |
| public List | |
| public Predicate | Returns: having clause predicateReturn the predicate that corresponds to the restriction(s) over the grouping items, or null if no restrictions have been specified. |
| public Class | |
| public Set | |
| public Selection | Returns: selection itemReturn the selection of the query, or null if no selection has been set. |
| public AbstractQuery | Returns: the modified queryzero or more grouping expressions grouping)Specify the expressions that are used to form groups over the query results. |
| public AbstractQuery | Returns: the modified querylist of zero or more grouping expressions grouping)Specify the expressions that are used to form groups over the query results. |
| public AbstractQuery | Returns: the modified querya simple or compound boolean expression restriction)Specify a restriction over the groups of the query. |
| public AbstractQuery | |
| public AbstractQuery | |
| public boolean | Returns: boolean indicating whether duplicate query results must be eliminatedReturn whether duplicate query results must be eliminated or retained. |
| public AbstractQuery | Returns: the modified querya simple or compound boolean expression restriction)Modify the query to restrict the query results according to the specified boolean expression. |
| public AbstractQuery | |
| public AbstractQuery |
| distinct | back to summary |
|---|---|
| public AbstractQuery Specify whether duplicate query results are eliminated. A true value will cause duplicates to be eliminated. A false value will cause duplicates to be retained. If distinct has not been specified, duplicate results must be retained.
| |
| from | back to summary |
|---|---|
| public <X> Root Create and add a query root corresponding to the given entity, forming a cartesian product with any existing roots. | |
| from | back to summary |
|---|---|
| public <X> Root Create and add a query root corresponding to the given entity, forming a cartesian product with any existing roots.
| |
| getGroupList | back to summary |
|---|---|
| public List Return a list of the grouping expressions. Returns empty list if no grouping expressions have been specified. Modifications to the list do not affect the query.
| |
| getGroupRestriction | back to summary |
|---|---|
| public Predicate getGroupRestriction() Return the predicate that corresponds to the restriction(s) over the grouping items, or null if no restrictions have been specified.
| |
| getResultType | back to summary |
|---|---|
| public Class Return the result type of the query or subquery. If
a result type was specified as an argument to the
| |
| getRoots | back to summary |
|---|---|
| public Set Return the query roots. These are the roots that are
defined for the | |
| getSelection | back to summary |
|---|---|
| public Selection Return the selection of the query, or null if no selection has been set.
| |
| groupBy | back to summary |
|---|---|
| public AbstractQuery Specify the expressions that are used to form groups over the query results. Replaces the previous specified grouping expressions, if any. If no grouping expressions are specified, any previously added grouping expressions are simply removed.
| |
| groupBy | back to summary |
|---|---|
| public AbstractQuery Specify the expressions that are used to form groups over the query results. Replaces the previous specified grouping expressions, if any. If no grouping expressions are specified, any previously added grouping expressions are simply removed.
| |
| having | back to summary |
|---|---|
| public AbstractQuery Specify a restriction over the groups of the query. Replaces the previous having restriction(s), if any.
| |
| having | back to summary |
|---|---|
| public AbstractQuery Specify restrictions over the groups of the query according the conjunction of the specified restriction predicates. Replaces the previously having added restriction(s), if any. If no restrictions are specified, any previously added restrictions are simply removed.
| |
| having | back to summary |
|---|---|
| public AbstractQuery Specify restrictions over the groups of the query according the conjunction of the specified restriction predicates. Replaces the previously added having restriction(s), if any. If no restrictions are specified, any previously added restrictions are simply removed.
| |
| isDistinct | back to summary |
|---|---|
| public boolean isDistinct() Return whether duplicate query results must be eliminated or retained.
| |
| where | back to summary |
|---|---|
| public AbstractQuery Modify the query to restrict the query results according to the specified boolean expression. Replaces the previously added restriction(s), if any.
| |
| where | back to summary |
|---|---|
| public AbstractQuery Modify the query to restrict the query results according to the conjunction of the specified restriction predicates. Replaces the previously added restriction(s), if any. If no restrictions are specified, any previously added restrictions are simply removed.
| |
| where | back to summary |
|---|---|
| public AbstractQuery Modify the query to restrict the query result according to the conjunction of the specified restriction predicates. Replaces the previously added restriction(s), if any. If no restrictions are specified, any previously added restrictions are simply removed.
| |