| 
||||||||||
| PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
| SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD | |||||||||
java.lang.Objectcom.mysema.query.support.QueryBase<Q>
com.mysema.query.support.ProjectableQuery<Q>
com.mysema.query.jpa.JPQLQueryBase<Q>
com.mysema.query.jpa.hibernate.AbstractHibernateQuery<Q>
Q - public abstract class AbstractHibernateQuery<Q extends AbstractHibernateQuery<Q>>
Abstract base class for Hibernate API based implementations of the JPQL interface
| Field Summary | |
|---|---|
protected  Boolean | 
cacheable
 | 
protected  String | 
cacheRegion
 | 
protected  String | 
comment
 | 
protected  int | 
fetchSize
 | 
protected  org.hibernate.FlushMode | 
flushMode
 | 
protected  Map<Path<?>,org.hibernate.LockMode> | 
lockModes
 | 
protected  Boolean | 
readOnly
 | 
protected  int | 
timeout
 | 
| Constructor Summary | |
|---|---|
AbstractHibernateQuery(org.hibernate.Session session)
 | 
|
AbstractHibernateQuery(SessionHolder session,
                       JPQLTemplates patterns,
                       QueryMetadata metadata)
 | 
|
| Method Summary | ||
|---|---|---|
 long | 
count()
return the amount of matched rows  | 
|
 org.hibernate.Query | 
createQuery(Expression<?> expr)
Expose the original Hibernate query for the given projection  | 
|
 org.hibernate.Query | 
createQuery(Expression<?>[] args)
Expose the original Hibernate query for the given projection  | 
|
 org.hibernate.Query | 
createQuery(Expression<?> expr1,
            Expression<?> expr2,
            Expression<?>... rest)
Expose the original Hibernate query for the given projection  | 
|
 com.mysema.commons.lang.CloseableIterator<Object[]> | 
iterate(Expression<?>[] args)
Return the query results as an Iterator.  | 
|
 | 
iterate(Expression<RT> projection)
Return the query results as an Iterator.  | 
|
 List<Object[]> | 
list(Expression<?>[] args)
list the results for the given projection An empty list is returned for no results.  | 
|
 | 
list(Expression<RT> expr)
list the results for the given projection An empty list is returned for no results.  | 
|
 | 
listResults(Expression<RT> expr)
list the results for the given projection  | 
|
protected  void | 
logQuery(String queryString)
 | 
|
 org.hibernate.ScrollableResults | 
scroll(org.hibernate.ScrollMode mode,
       Expression<?> expr)
Return the query results as ScrollableResults.  | 
|
 org.hibernate.ScrollableResults | 
scroll(org.hibernate.ScrollMode mode,
       Expression<?>[] args)
Return the query results as ScrollableResults.  | 
|
 org.hibernate.ScrollableResults | 
scroll(org.hibernate.ScrollMode mode,
       Expression<?> expr1,
       Expression<?> expr2,
       Expression<?>... rest)
Return the query results as ScrollableResults.  | 
|
 Q | 
setCacheable(boolean cacheable)
Enable caching of this query result set.  | 
|
 Q | 
setCacheRegion(String cacheRegion)
Set the name of the cache region.  | 
|
 Q | 
setComment(String comment)
Add a comment to the generated SQL.  | 
|
 Q | 
setFetchSize(int fetchSize)
Set a fetch size for the underlying JDBC query.  | 
|
 Q | 
setFlushMode(org.hibernate.FlushMode flushMode)
Override the current session flush mode, just for this query.  | 
|
 Q | 
setLockMode(Path<?> path,
            org.hibernate.LockMode lockMode)
Set the lock mode for the given path.  | 
|
 Q | 
setReadOnly(boolean readOnly)
Entities retrieved by this query will be loaded in a read-only mode where Hibernate will never dirty-check them or make changes persistent.  | 
|
 Q | 
setTimeout(int timeout)
Set a timeout for the underlying JDBC query.  | 
|
 Object[] | 
uniqueResult(Expression<?>[] args)
return a unique result for the given projection or null if no result is found  | 
|
 | 
uniqueResult(Expression<RT> expr)
return a unique result for the given projection or null if no result is found  | 
|
| Methods inherited from class com.mysema.query.jpa.JPQLQueryBase | 
|---|
buildQueryString, exists, fetch, fetchAll, from, fullJoin, fullJoin, fullJoin, fullJoin, fullJoin, fullJoin, getConstants, getMetadata, getQueryMixin, getTemplates, innerJoin, innerJoin, innerJoin, innerJoin, innerJoin, innerJoin, join, join, join, join, join, join, leftJoin, leftJoin, leftJoin, leftJoin, leftJoin, leftJoin, reset, setConstants, toCountRowsString, toQueryString, toString, with | 
| Methods inherited from class com.mysema.query.support.ProjectableQuery | 
|---|
countDistinct, iterate, iterateDistinct, iterateDistinct, iterateDistinct, list, listDistinct, listDistinct, listDistinct, listDistinctResults, map, notExists, singleResult, singleResult, singleResult, transform, uniqueResult, uniqueResult | 
| Methods inherited from class com.mysema.query.support.QueryBase | 
|---|
distinct, groupBy, having, limit, offset, orderBy, restrict, set, where | 
| Methods inherited from class java.lang.Object | 
|---|
clone, equals, finalize, getClass, hashCode, notify, notifyAll, wait, wait, wait | 
| Field Detail | 
|---|
@Nullable protected Boolean cacheable
@Nullable protected Boolean readOnly
@Nullable protected String cacheRegion
@Nullable protected String comment
protected int fetchSize
protected final Map<Path<?>,org.hibernate.LockMode> lockModes
@Nullable protected org.hibernate.FlushMode flushMode
protected int timeout
| Constructor Detail | 
|---|
public AbstractHibernateQuery(org.hibernate.Session session)
public AbstractHibernateQuery(SessionHolder session,
                              JPQLTemplates patterns,
                              QueryMetadata metadata)
| Method Detail | 
|---|
public long count()
Projectable
public org.hibernate.Query createQuery(Expression<?> expr)
expr - 
public org.hibernate.Query createQuery(Expression<?> expr1,
                                       Expression<?> expr2,
                                       Expression<?>... rest)
expr1 - expr2 - rest - 
public org.hibernate.Query createQuery(Expression<?>[] args)
args - 
public com.mysema.commons.lang.CloseableIterator<Object[]> iterate(Expression<?>[] args)
public <RT> com.mysema.commons.lang.CloseableIterator<RT> iterate(Expression<RT> projection)
RT - generic type of the Iterator
public List<Object[]> list(Expression<?>[] args)
Projectable
list in interface Projectablelist in class ProjectableQuery<Q extends AbstractHibernateQuery<Q>>public <RT> List<RT> list(Expression<RT> expr)
Projectable
list in interface Projectablelist in class ProjectableQuery<Q extends AbstractHibernateQuery<Q>>RT - generic type of the List
public <RT> SearchResults<RT> listResults(Expression<RT> expr)
Projectable
protected void logQuery(String queryString)
public org.hibernate.ScrollableResults scroll(org.hibernate.ScrollMode mode,
                                              Expression<?> expr)
mode - expr - 
public org.hibernate.ScrollableResults scroll(org.hibernate.ScrollMode mode,
                                              Expression<?> expr1,
                                              Expression<?> expr2,
                                              Expression<?>... rest)
mode - expr1 - expr2 - rest - 
public org.hibernate.ScrollableResults scroll(org.hibernate.ScrollMode mode,
                                              Expression<?>[] args)
mode - args - 
public Q setCacheable(boolean cacheable)
cacheable - Should the query results be cacheable?public Q setCacheRegion(String cacheRegion)
cacheRegion - the name of a query cache region, or null
 for the default query cachepublic Q setComment(String comment)
comment - 
public Q setFetchSize(int fetchSize)
fetchSize - the fetch size
public Q setLockMode(Path<?> path,
                     org.hibernate.LockMode lockMode)
public Q setFlushMode(org.hibernate.FlushMode flushMode)
public Q setReadOnly(boolean readOnly)
public Q setTimeout(int timeout)
timeout - the timeout in secondspublic <RT> RT uniqueResult(Expression<RT> expr)
ProjectableThere is some ambiguity for missing results and null valued results, for disambiguation and your own projection methods.
RT - return type
public Object[] uniqueResult(Expression<?>[] args)
ProjectableThere is some ambiguity for missing results and null valued results, for disambiguation and your own projection methods.
  | 
||||||||||
| PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
| SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD | |||||||||