Class EntityBatchLoaderInPredicate<T>
java.lang.Object
org.hibernate.loader.ast.internal.SingleIdEntityLoaderSupport<T>
org.hibernate.loader.ast.internal.AbstractEntityBatchLoader<T>
org.hibernate.loader.ast.internal.EntityBatchLoaderInPredicate<T>
- All Implemented Interfaces:
BatchLoader,EntityBatchLoader<T>,EntityLoader,Loader,MultiKeyLoader,SingleEntityLoader<T>,SingleIdEntityLoader<T>,SqlInPredicateMultiKeyLoader
public class EntityBatchLoaderInPredicate<T>
extends AbstractEntityBatchLoader<T>
implements SqlInPredicateMultiKeyLoader
An
EntityBatchLoader using one or more SQL queries, which each initialize up
to getSqlBatchSize() entities using a SQL IN predicate restriction -
e.g., ... where id in (?,?,...).
The number of parameters rendered into the SQL is controlled by getSqlBatchSize().
Any unused parameter slots for a particular execution are set to null.
-
Field Summary
Fields inherited from class org.hibernate.loader.ast.internal.SingleIdEntityLoaderSupport
sessionFactory -
Constructor Summary
ConstructorsConstructorDescriptionEntityBatchLoaderInPredicate(int domainBatchSize, EntityMappingType entityDescriptor, LoadQueryInfluencers loadQueryInfluencers) -
Method Summary
Modifier and TypeMethodDescriptionintThe total number of loadable references that can be initialized per each load operation.intprotected voidinitializeEntities(Object[] idsToInitialize, Object pkValue, Object entityInstance, LockOptions lockOptions, Boolean readOnly, SharedSessionContractImplementor session) final Tload(Object pkValue, LockOptions lockOptions, Boolean readOnly, SharedSessionContractImplementor session) Load by primary key valueprotected Object[]resolveIdsToInitialize(Object id, SharedSessionContractImplementor session) toString()Methods inherited from class org.hibernate.loader.ast.internal.AbstractEntityBatchLoader
load, loadMethods inherited from class org.hibernate.loader.ast.internal.SingleIdEntityLoaderSupport
getLoadable, loadDatabaseSnapshotMethods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, wait, wait, waitMethods inherited from interface org.hibernate.loader.ast.spi.SingleEntityLoader
getLoadableMethods inherited from interface org.hibernate.loader.ast.spi.SingleIdEntityLoader
loadDatabaseSnapshot
-
Constructor Details
-
EntityBatchLoaderInPredicate
public EntityBatchLoaderInPredicate(int domainBatchSize, EntityMappingType entityDescriptor, LoadQueryInfluencers loadQueryInfluencers) - Parameters:
domainBatchSize- The maximum number of entities we will initialize for each load
-
-
Method Details
-
getDomainBatchSize
public int getDomainBatchSize()Description copied from interface:BatchLoaderThe total number of loadable references that can be initialized per each load operation.- Specified by:
getDomainBatchSizein interfaceBatchLoader
-
getSqlBatchSize
public int getSqlBatchSize() -
toString
-