Package net.officefloor.jpa
Interface JpaManagedObjectSource.PersistenceFactory
-
- All Known Implementing Classes:
DataNucleusJpaManagedObjectSource
,HibernateJpaManagedObjectSource
- Enclosing class:
- JpaManagedObjectSource
- Functional Interface:
- This is a functional interface and can therefore be used as the assignment target for a lambda expression or method reference.
@FunctionalInterface public static interface JpaManagedObjectSource.PersistenceFactory
FunctionalInterface
to create theEntityManagerFactory
.Note: the
EntityManagerFactory
is required to be configured with the inputDataSource
.
-
-
Method Summary
All Methods Instance Methods Abstract Methods Modifier and Type Method Description javax.persistence.EntityManagerFactory
createEntityManagerFactory(java.lang.String persistenceUnitName, javax.sql.DataSource dataSource, java.util.Properties properties)
Creates theEntityManagerFactory
.
-
-
-
Method Detail
-
createEntityManagerFactory
javax.persistence.EntityManagerFactory createEntityManagerFactory(java.lang.String persistenceUnitName, javax.sql.DataSource dataSource, java.util.Properties properties) throws java.lang.Exception
Creates theEntityManagerFactory
.- Parameters:
persistenceUnitName
- Persistence Unit name.dataSource
-DataSource
to use for theEntityManagerFactory
.null
ifEntityManagerFactory
to create and manage theDataSource
.properties
- Existing properties configured to theJpaManagedObjectSource
.- Returns:
- Configuration for the
EntityManagerFactory
to use theDataSource
. - Throws:
java.lang.Exception
- If fails to create theEntityManagerFactory
.
-
-