Package com.querydsl.jpa
Interface QueryHandler
- All Known Implementing Classes:
DefaultQueryHandler,HibernateHandler
public interface QueryHandler
QueryHandler provides injection of provider specific functionality into the query logic- Author:
- tiwe
-
Method Summary
Modifier and TypeMethodDescriptionvoidAdd the given entity to the given native queryvoidAdd the given scalar to the given native querybooleanReturn whether native queries should be created as typed queries<T> com.mysema.commons.lang.CloseableIterator<T>iterate(javax.persistence.Query query, @Nullable FactoryExpression<?> projection) Iterate the results with the optional projection<T> Stream<T>stream(javax.persistence.Query query, @Nullable FactoryExpression<?> projection) Stream the results with the optional projectionbooleantransform(javax.persistence.Query query, FactoryExpression<?> projection) Transform the results of the given query using the given factory expressionbooleanReturn whether entity projections need to be wrapped
-
Method Details
-
createNativeQueryTyped
boolean createNativeQueryTyped()Return whether native queries should be created as typed queries- Returns:
- whether native queries should be created as typed queries
-
iterate
<T> com.mysema.commons.lang.CloseableIterator<T> iterate(javax.persistence.Query query, @Nullable @Nullable FactoryExpression<?> projection) Iterate the results with the optional projection- Parameters:
query- query- Returns:
- iterator
-
stream
<T> Stream<T> stream(javax.persistence.Query query, @Nullable @Nullable FactoryExpression<?> projection) Stream the results with the optional projection- Parameters:
query- query- Returns:
- stream
-
addScalar
Add the given scalar to the given native query- Parameters:
query- queryalias- aliastype- type
-
addEntity
Add the given entity to the given native query- Parameters:
query- queryalias- aliastype- type
-
transform
Transform the results of the given query using the given factory expression- Parameters:
query- queryprojection- projection- Returns:
- true, if query as been modified
-
wrapEntityProjections
boolean wrapEntityProjections()Return whether entity projections need to be wrapped- Returns:
- whether entity projections need to be wrapped
-