Package org.apache.openjpa.persistence
Interface OpenJPAEntityManagerFactory
- All Superinterfaces:
jakarta.persistence.EntityManagerFactory,Serializable
- All Known Subinterfaces:
OpenJPAEntityManagerFactorySPI
- All Known Implementing Classes:
EntityManagerFactoryImpl
public interface OpenJPAEntityManagerFactory
extends jakarta.persistence.EntityManagerFactory, Serializable
Interface implemented by OpenJPA entity manager factories.
- Since:
- 0.4.0
- Author:
- Abe White
-
Field Summary
FieldsModifier and TypeFieldDescriptionstatic final intDeprecated.static final intDeprecated.useConnectionRetainModeenums instead.static final intDeprecated.useConnectionRetainModeenums instead. -
Method Summary
Modifier and TypeMethodDescriptionvoidaddLifecycleListener(Object listener, Class... classes) Deprecated.cast toOpenJPAEntityManagerFactorySPIinstead.voidaddTransactionListener(Object listener) Deprecated.cast toOpenJPAEntityManagerFactorySPIinstead.createEntityManager(Map props) Return an entity manager with the provided additional configuration settings.Deprecated.cast toOpenJPAEntityManagerFactorySPIinstead.Gets the QueryBuilder with OpenJPA-extended capabilities.Gets a builder for dynamic queries.Return properties describing this runtime.Access query result cache.Access the level 2 store cache.getStoreCache(String name) Access a named level 2 store cache.Get the properties supported by this runtime.getUserObject(Object key) Get the value for the specified key from the map of user objects.putUserObject(Object key, Object val) Put the specified key-value pair into the map of user objects.voidremoveLifecycleListener(Object listener) Deprecated.cast toOpenJPAEntityManagerFactorySPIinstead.voidremoveTransactionListener(Object listener) Deprecated.cast toOpenJPAEntityManagerFactorySPIinstead.Methods inherited from interface jakarta.persistence.EntityManagerFactory
addNamedEntityGraph, addNamedQuery, close, createEntityManager, createEntityManager, getCache, getMetamodel, getPersistenceUnitUtil, isOpen, unwrap
-
Field Details
-
CONN_RETAIN_DEMAND
Deprecated.useConnectionRetainModeenums instead.- See Also:
-
CONN_RETAIN_TRANS
Deprecated.useConnectionRetainModeenums instead.- See Also:
-
CONN_RETAIN_ALWAYS
Deprecated.useConnectionRetainModeenums instead.- See Also:
-
-
Method Details
-
getProperties
Return properties describing this runtime.- Specified by:
getPropertiesin interfacejakarta.persistence.EntityManagerFactory
-
putUserObject
Put the specified key-value pair into the map of user objects. -
getUserObject
Get the value for the specified key from the map of user objects. -
getStoreCache
StoreCache getStoreCache()Access the level 2 store cache. This cache acts as a proxy to all named caches. -
getStoreCache
Access a named level 2 store cache. -
getQueryResultCache
QueryResultCache getQueryResultCache()Access query result cache. -
createEntityManager
OpenJPAEntityManager createEntityManager()- Specified by:
createEntityManagerin interfacejakarta.persistence.EntityManagerFactory
-
createEntityManager
Return an entity manager with the provided additional configuration settings. OpenJPA recognizes the following configuration settings in this method:- openjpa.ConnectionUsername
- openjpa.ConnectionPassword
- openjpa.ConnectionRetainMode
- openjpa.TransactionMode
- Specified by:
createEntityManagerin interfacejakarta.persistence.EntityManagerFactory
-
getConfiguration
Deprecated.cast toOpenJPAEntityManagerFactorySPIinstead. This method pierces the published-API boundary, as does the SPI cast. -
addLifecycleListener
Deprecated.cast toOpenJPAEntityManagerFactorySPIinstead. This method pierces the published-API boundary, as does the SPI cast. -
removeLifecycleListener
Deprecated.cast toOpenJPAEntityManagerFactorySPIinstead. This method pierces the published-API boundary, as does the SPI cast. -
addTransactionListener
Deprecated.cast toOpenJPAEntityManagerFactorySPIinstead. This method pierces the published-API boundary, as does the SPI cast. -
removeTransactionListener
Deprecated.cast toOpenJPAEntityManagerFactorySPIinstead. This method pierces the published-API boundary, as does the SPI cast. -
getDynamicQueryBuilder
QueryBuilder getDynamicQueryBuilder()Gets a builder for dynamic queries. -
getCriteriaBuilder
OpenJPACriteriaBuilder getCriteriaBuilder()Gets the QueryBuilder with OpenJPA-extended capabilities.- Specified by:
getCriteriaBuilderin interfacejakarta.persistence.EntityManagerFactory- Since:
- 2.0.0
-
getSupportedProperties
Get the properties supported by this runtime.- Since:
- 2.0.0
-
ConnectionRetainModeenums instead.