Class EntityBatchLoaderArrayParam<T>
java.lang.Object
org.hibernate.loader.ast.internal.SingleIdEntityLoaderSupport<T>
org.hibernate.loader.ast.internal.AbstractEntityBatchLoader<T>
org.hibernate.loader.ast.internal.EntityBatchLoaderArrayParam<T>
- All Implemented Interfaces:
BatchLoader,EntityBatchLoader<T>,EntityLoader,Loader,MultiKeyLoader,SingleEntityLoader<T>,SingleIdEntityLoader<T>,SqlArrayMultiKeyLoader
public class EntityBatchLoaderArrayParam<T>
extends AbstractEntityBatchLoader<T>
implements SqlArrayMultiKeyLoader
SingleIdEntityLoaderSupport implementation based on using a single
array parameter to pass the
entire batch of ids.-
Field Summary
Fields inherited from class org.hibernate.loader.ast.internal.SingleIdEntityLoaderSupport
sessionFactory -
Constructor Summary
ConstructorsConstructorDescriptionEntityBatchLoaderArrayParam(int domainBatchSize, EntityMappingType entityDescriptor, LoadQueryInfluencers loadQueryInfluencers) Instantiates the loader -
Method Summary
Modifier and TypeMethodDescriptionintThe total number of loadable references that can be initialized per each load operation.protected voidinitializeEntities(Object[] idsToInitialize, Object id, Object entityInstance, LockOptions lockOptions, Boolean readOnly, SharedSessionContractImplementor session) load(Object pkValue, LockOptions lockOptions, Boolean readOnly, SharedSessionContractImplementor session) Load by primary key valueprotected Object[]resolveIdsToInitialize(Object pkValue, 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
-
EntityBatchLoaderArrayParam
public EntityBatchLoaderArrayParam(int domainBatchSize, EntityMappingType entityDescriptor, LoadQueryInfluencers loadQueryInfluencers) Instantiates the loader- Parameters:
domainBatchSize- The number of domain model parts (up to)- Implementation Note:
- We delay initializing the internal SQL AST state until first use. Creating
the SQL AST internally relies on the entity's
EntityIdentifierMapping. However, we do create the static batch-loader for the entity in the persister constructor andEntityIdentifierMappingis not available at that time. On first use, we know we have it available
-
-
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
-
toString
-