Package org.hibernate.jpa.boot.internal
Class EntityManagerFactoryBuilderImpl
java.lang.Object
org.hibernate.jpa.boot.internal.EntityManagerFactoryBuilderImpl
- All Implemented Interfaces:
EntityManagerFactoryBuilder
-
Field Summary
FieldsModifier and TypeFieldDescriptionstatic final String
Names aIntegratorProvider
static final String
Names aMetadataBuilderContributor
static final String
Names aStrategyRegistrationProviderList
static final String
Names aTypeContributorList
-
Constructor Summary
ConstructorsConstructorDescriptionEntityManagerFactoryBuilderImpl
(PersistenceUnitDescriptor persistenceUnit, Map<String, Object> integrationSettings) EntityManagerFactoryBuilderImpl
(PersistenceUnitDescriptor persistenceUnit, Map<String, Object> integrationSettings, ClassLoader providedClassLoader) EntityManagerFactoryBuilderImpl
(PersistenceUnitDescriptor persistenceUnitDescriptor, Map<String, Object> integration, Consumer<MergedSettings> mergedSettingsBaseline) For tests onlyEntityManagerFactoryBuilderImpl
(PersistenceUnitDescriptor persistenceUnit, Map<String, Object> integrationSettings, ClassLoaderService providedClassLoaderService) -
Method Summary
Modifier and TypeMethodDescriptionbuild()
BuildEntityManagerFactory
instancevoid
cancel()
Cancel the building processing.void
Perform an explicit schema generation (rather than an "auto" one) based on theprotected EnhancementContext
getEnhancementContext
(boolean dirtyTrackingEnabled, boolean lazyInitializationEnabled, boolean associationManagementEnabled) Builds the context to be used in runtime bytecode enhancementIntended for internal testing only...protected StandardServiceRegistry
Exposed to extensions: see Hibernate Reactiveprotected StandardServiceRegistryBuilder
Extension point for subclasses.metadata()
Used by extensions : Hibernate Reactiveprotected SessionFactoryBuilder
withDataSource
(DataSource dataSource) Allows passing in a DataSource (delayed from constructing the builder, AKA phase 2) to be used in building the EntityManagerFactorywithValidatorFactory
(Object validatorFactory) Allows passing in a Java EE ValidatorFactory (delayed from constructing the builder, AKA phase 2) to be used in building the EntityManagerFactory
-
Field Details
-
INTEGRATOR_PROVIDER
Names aIntegratorProvider
- See Also:
-
STRATEGY_REGISTRATION_PROVIDERS
Names aStrategyRegistrationProviderList
- See Also:
-
TYPE_CONTRIBUTORS
Names aTypeContributorList
- See Also:
-
METADATA_BUILDER_CONTRIBUTOR
Names aMetadataBuilderContributor
- See Also:
-
-
Constructor Details
-
EntityManagerFactoryBuilderImpl
public EntityManagerFactoryBuilderImpl(PersistenceUnitDescriptor persistenceUnit, Map<String, Object> integrationSettings) -
EntityManagerFactoryBuilderImpl
public EntityManagerFactoryBuilderImpl(PersistenceUnitDescriptor persistenceUnit, Map<String, Object> integrationSettings, ClassLoader providedClassLoader) -
EntityManagerFactoryBuilderImpl
public EntityManagerFactoryBuilderImpl(PersistenceUnitDescriptor persistenceUnit, Map<String, Object> integrationSettings, ClassLoaderService providedClassLoaderService) -
EntityManagerFactoryBuilderImpl
@Internal public EntityManagerFactoryBuilderImpl(PersistenceUnitDescriptor persistenceUnitDescriptor, Map<String, Object> integration, Consumer<MergedSettings> mergedSettingsBaseline) For tests only
-
-
Method Details
-
getStandardServiceRegistryBuilder
protected StandardServiceRegistryBuilder getStandardServiceRegistryBuilder(BootstrapServiceRegistry bsr) Extension point for subclasses. Used by Hibernate Reactive -
getConfigurationValues
-
getEnhancementContext
protected EnhancementContext getEnhancementContext(boolean dirtyTrackingEnabled, boolean lazyInitializationEnabled, boolean associationManagementEnabled) Builds the context to be used in runtime bytecode enhancement- Parameters:
dirtyTrackingEnabled
- To enable dirty tracking featurelazyInitializationEnabled
- To enable lazy initialization featureassociationManagementEnabled
- To enable association management feature- Returns:
- An enhancement context for classes managed by this EM
-
getMetadata
Intended for internal testing only... -
getManagedResources
- Specified by:
getManagedResources
in interfaceEntityManagerFactoryBuilder
-
metadata
Used by extensions : Hibernate Reactive- Specified by:
metadata
in interfaceEntityManagerFactoryBuilder
-
withValidatorFactory
Description copied from interface:EntityManagerFactoryBuilder
Allows passing in a Java EE ValidatorFactory (delayed from constructing the builder, AKA phase 2) to be used in building the EntityManagerFactory- Specified by:
withValidatorFactory
in interfaceEntityManagerFactoryBuilder
- Parameters:
validatorFactory
- The ValidatorFactory- Returns:
this
, for method chaining
-
withDataSource
Description copied from interface:EntityManagerFactoryBuilder
Allows passing in a DataSource (delayed from constructing the builder, AKA phase 2) to be used in building the EntityManagerFactory- Specified by:
withDataSource
in interfaceEntityManagerFactoryBuilder
- Parameters:
dataSource
- The DataSource to use- Returns:
this
, for method chaining
-
cancel
public void cancel()Description copied from interface:EntityManagerFactoryBuilder
Cancel the building processing. This is used to signal the builder to release any resources in the case of something having gone wrong during the bootstrap process- Specified by:
cancel
in interfaceEntityManagerFactoryBuilder
-
generateSchema
public void generateSchema()Description copied from interface:EntityManagerFactoryBuilder
Perform an explicit schema generation (rather than an "auto" one) based on the- Specified by:
generateSchema
in interfaceEntityManagerFactoryBuilder
-
build
Description copied from interface:EntityManagerFactoryBuilder
BuildEntityManagerFactory
instance- Specified by:
build
in interfaceEntityManagerFactoryBuilder
- Returns:
- The built
EntityManagerFactory
-
populateSessionFactoryBuilder
-
getStandardServiceRegistry
Exposed to extensions: see Hibernate Reactive
-