public interface BytecodeEnhancementMetadata
String getEntityName()
boolean isEnhancedForLazyLoading()
true
indicates the entity class is enhanced for Hibernate use
in lazy loading; false
indicates it is notLazyAttributesMetadata getLazyAttributesMetadata()
PersistentAttributeInterceptable createEnhancedProxy(EntityKey keyToLoad, boolean addEmptyEntry, SharedSessionContractImplementor session)
LazyAttributeLoadingInterceptor injectInterceptor(Object entity, Object identifier, SharedSessionContractImplementor session) throws NotInstrumentedException
entity
- The entity into which built interceptor should be injectedidentifier
- session
- The session to which the entity instance belongs.NotInstrumentedException
- Thrown if isEnhancedForLazyLoading()
returns false
void injectInterceptor(Object entity, PersistentAttributeInterceptor interceptor, SharedSessionContractImplementor session)
void injectEnhancedEntityAsProxyInterceptor(Object entity, EntityKey entityKey, SharedSessionContractImplementor session)
LazyAttributeLoadingInterceptor extractInterceptor(Object entity) throws NotInstrumentedException
entity
- The entity from which to extract the interceptorNotInstrumentedException
- Thrown if isEnhancedForLazyLoading()
returns false
BytecodeLazyAttributeInterceptor extractLazyInterceptor(Object entity) throws NotInstrumentedException
NotInstrumentedException
boolean hasUnFetchedAttributes(Object entity)
Copyright © 2001-2019 Red Hat, Inc. All Rights Reserved.