Class HibernateBridgingQueryHints
java.lang.Object
org.broadleafcommerce.common.persistence.HibernateBridgingQueryHints
Serves as a bridge class between Hibernate 4.1 and Hibernate 5.2. Designed to map directly to the org.hibernate.annotations.QueryHints static fields that appear in both Hibernate 4.1 and 5.2 but are named differently.
This class was duplicated directly from QueryHints as it contains
all of the values from Hibernate 4.1 as well as additional values from Hibernate 5.2.
This class should only be used if you need Hibernate 4.1 (Broadleaf 5.2 and below) and Hibernate 5.2 (Broadleaf 6.0+) within the same artifact. This is a stop-gap solution to prevent hard-dependency upgrades within the Broadleaf platform and is not intended to be consumed by Broadleaf users.
- Author:
- Phillip Verheyden (phillipuniverse)
-
Nested Class Summary
Nested ClassesModifier and TypeClassDescriptionstatic classAll constants within this inner class only appear in Hibernate 5.2+ (Broadleaf 6.0+) and are not guaranteed to work when running Hibernate versions earlier than 5.2. -
Field Summary
FieldsModifier and TypeFieldDescriptionstatic final StringThe cache mode to use.static final StringThe cache region to use.static final StringAre the query results cacheable?static final StringIs the query callable? Note: only valid for named native sql queries.static final StringDefines a comment to be applied to the SQL sent to the database.static final StringDefines the JDBC fetch size to use.static final StringThe flush mode to associate with the execution of the query.static final StringShould entities returned from the query be set in read only mode?static final StringApply a Hibernate query timeout, which is defined in seconds.static final StringApply a JPA query timeout, which is defined in milliseconds. -
Method Summary
-
Field Details
-
CACHE_MODE
The cache mode to use.- See Also:
-
Query.setCacheMode(org.hibernate.CacheMode)SQLQuery.setCacheMode(org.hibernate.CacheMode)- Constant Field Values
-
CACHE_REGION
The cache region to use.- See Also:
-
Query.setCacheRegion(java.lang.String)SQLQuery.setCacheRegion(java.lang.String)- Constant Field Values
-
CACHEABLE
Are the query results cacheable?- See Also:
-
Query.setCacheable(boolean)SQLQuery.setCacheable(boolean)- Constant Field Values
-
CALLABLE
Is the query callable? Note: only valid for named native sql queries.- See Also:
-
COMMENT
Defines a comment to be applied to the SQL sent to the database.- See Also:
-
Query.setComment(java.lang.String)SQLQuery.setComment(java.lang.String)- Constant Field Values
-
FETCH_SIZE
Defines the JDBC fetch size to use.- See Also:
-
Query.setFetchSize(int)SQLQuery.setFetchSize(int)- Constant Field Values
-
FLUSH_MODE
The flush mode to associate with the execution of the query.- See Also:
-
Query.setFlushMode(org.hibernate.FlushMode)SQLQuery.setFlushMode(javax.persistence.FlushModeType)Session.setFlushMode(org.hibernate.FlushMode)- Constant Field Values
-
READ_ONLY
Should entities returned from the query be set in read only mode?- See Also:
-
Query.setReadOnly(boolean)SQLQuery.setReadOnly(boolean)Session.setReadOnly(java.lang.Object, boolean)- Constant Field Values
-
TIMEOUT_HIBERNATE
Apply a Hibernate query timeout, which is defined in seconds.- See Also:
-
Query.setTimeout(int)SQLQuery.setTimeout(int)- Constant Field Values
-
TIMEOUT_JPA
Apply a JPA query timeout, which is defined in milliseconds.- See Also:
-