|
||||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |
java.lang.Object com.mysema.query.support.QueryBase<Q> com.mysema.query.support.ProjectableQuery<Q>
public abstract class ProjectableQuery<Q extends ProjectableQuery<Q>>
ProjectableQuery extends the QueryBase class to provide default implementations of the methods of the Projectable interface
Field Summary |
---|
Fields inherited from class com.mysema.query.support.QueryBase |
---|
queryMixin |
Constructor Summary | |
---|---|
ProjectableQuery(QueryMixin<Q> queryMixin)
|
Method Summary | ||
---|---|---|
long |
countDistinct()
return the amount of distinct matched rows |
|
com.mysema.commons.lang.CloseableIterator<Object[]> |
iterate(Expression<?> first,
Expression<?> second,
Expression<?>... rest)
iterate over the results for the given projection |
|
com.mysema.commons.lang.CloseableIterator<Object[]> |
iterateDistinct(Expression<?>[] args)
iterate over the distinct results for the given projection |
|
com.mysema.commons.lang.CloseableIterator<Object[]> |
iterateDistinct(Expression<?> first,
Expression<?> second,
Expression<?>... rest)
iterate over the distinct results for the given projection |
|
|
iterateDistinct(Expression<RT> projection)
iterate over the distinct results for the given projection |
|
List<Object[]> |
list(Expression<?>[] args)
list the results for the given projection An empty list is returned for no results. |
|
List<Object[]> |
list(Expression<?> first,
Expression<?> second,
Expression<?>... rest)
list the results for the given projection An empty list is returned for no results. |
|
|
list(Expression<RT> projection)
list the results for the given projection An empty list is returned for no results. |
|
List<Object[]> |
listDistinct(Expression<?>[] args)
list the distinct results for the given projection An empty list is returned for no results. |
|
List<Object[]> |
listDistinct(Expression<?> first,
Expression<?> second,
Expression<?>... rest)
list the distinct results for the given projection An empty list is returned for no results. |
|
|
listDistinct(Expression<RT> projection)
list the distinct results for the given projection An empty list is returned for no results. |
|
|
listDistinctResults(Expression<RT> projection)
list the distinct results for the given projection |
|
|
map(Expression<K> key,
Expression<V> value)
return the given projection as a Map instance using key and value for Map population An empty map is returned for no results. |
|
boolean |
notExists()
|
|
Object[] |
singleResult(Expression<?>[] args)
return a single result for the given projection or null if no result is found |
|
Object[] |
singleResult(Expression<?> first,
Expression<?> second,
Expression<?>... rest)
return a single result for the given projection or null if no result is found |
|
|
singleResult(Expression<RT> expr)
return a single result for the given projection or null if no result is found |
|
|
transform(ResultTransformer<T> transformer)
Apply the given transformer to this Projectable instance and return the results |
|
protected
|
uniqueResult(com.mysema.commons.lang.CloseableIterator<T> it)
|
|
Object[] |
uniqueResult(Expression<?> first,
Expression<?> second,
Expression<?>... rest)
return a unique result for the given projection or null if no result is found |
Methods inherited from class com.mysema.query.support.QueryBase |
---|
distinct, equals, groupBy, hashCode, having, limit, offset, orderBy, restrict, set, toString, where |
Methods inherited from class java.lang.Object |
---|
clone, finalize, getClass, notify, notifyAll, wait, wait, wait |
Methods inherited from interface com.mysema.query.Projectable |
---|
count, exists, iterate, iterate, listResults, uniqueResult, uniqueResult |
Constructor Detail |
---|
public ProjectableQuery(QueryMixin<Q> queryMixin)
Method Detail |
---|
public final long countDistinct()
Projectable
countDistinct
in interface Projectable
public final com.mysema.commons.lang.CloseableIterator<Object[]> iterate(Expression<?> first, Expression<?> second, Expression<?>... rest)
Projectable
iterate
in interface Projectable
public final com.mysema.commons.lang.CloseableIterator<Object[]> iterateDistinct(Expression<?> first, Expression<?> second, Expression<?>... rest)
Projectable
iterateDistinct
in interface Projectable
public final com.mysema.commons.lang.CloseableIterator<Object[]> iterateDistinct(Expression<?>[] args)
Projectable
iterateDistinct
in interface Projectable
public final <RT> com.mysema.commons.lang.CloseableIterator<RT> iterateDistinct(Expression<RT> projection)
Projectable
iterateDistinct
in interface Projectable
RT
- generic type of the Iteratpr
public final List<Object[]> list(Expression<?> first, Expression<?> second, Expression<?>... rest)
Projectable
list
in interface Projectable
rest
- rest
public List<Object[]> list(Expression<?>[] args)
Projectable
list
in interface Projectable
public <RT> List<RT> list(Expression<RT> projection)
Projectable
list
in interface Projectable
RT
- generic type of the List
public final List<Object[]> listDistinct(Expression<?> first, Expression<?> second, Expression<?>... rest)
Projectable
listDistinct
in interface Projectable
rest
- rest
public final List<Object[]> listDistinct(Expression<?>[] args)
Projectable
listDistinct
in interface Projectable
public final <RT> List<RT> listDistinct(Expression<RT> projection)
Projectable
listDistinct
in interface Projectable
RT
- generic type of the List
public final <RT> SearchResults<RT> listDistinctResults(Expression<RT> projection)
Projectable
listDistinctResults
in interface Projectable
public final <K,V> Map<K,V> map(Expression<K> key, Expression<V> value)
Projectable
map
in interface Projectable
public final boolean notExists()
notExists
in interface Projectable
public final Object[] singleResult(Expression<?> first, Expression<?> second, Expression<?>... rest)
Projectable
for multiple results only the first one is returned
singleResult
in interface Projectable
public final Object[] singleResult(Expression<?>[] args)
Projectable
There is some ambiguity for missing results and null valued results, for disambiguation use the list or iterate methods instead.
for multiple results only the first one is returned
singleResult
in interface Projectable
public final <RT> RT singleResult(Expression<RT> expr)
Projectable
There is some ambiguity for missing results and null valued results, for disambiguation use the list or iterate methods instead.
for multiple results only the first one is returned
singleResult
in interface Projectable
RT
- return type
public <T> T transform(ResultTransformer<T> transformer)
Projectable
transform
in interface Projectable
public final Object[] uniqueResult(Expression<?> first, Expression<?> second, Expression<?>... rest)
Projectable
There is some ambiguity for missing results and null valued results, for disambiguation use the list or iterate methods instead.
uniqueResult
in interface Projectable
@Nullable protected <T> T uniqueResult(com.mysema.commons.lang.CloseableIterator<T> it)
|
||||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |