Package de.xima.fc.filter.db
Class PluginEntityContext
java.lang.Object
de.xima.fc.filter.db.PluginEntityContext
- All Implemented Interfaces:
de.xima.cmn.dao.interfaces.IBaseEntityContext
,Closeable
,AutoCloseable
public class PluginEntityContext
extends Object
implements de.xima.cmn.dao.interfaces.IBaseEntityContext, AutoCloseable, Closeable
An entity context for use by an entities plugin. Normally, you should not create this context manually, use
IPluginEmManager.newEntityContext()
instead.
This entity context implements AutoCloseable
. Calling the close()
will close the
EntityManager
if
- the entity manager was created by this class during a call to
getEm()
; and - we are currently not within the context of an HTTP request that is managed by the
ConnectionFilter
- Author:
- XIMA MEDIA GmbH
-
Constructor Summary
Constructors -
Method Summary
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
Methods inherited from interface de.xima.cmn.dao.interfaces.IBaseEntityContext
getFeatures, getPostCommitListeners, getPostRollbackListeners, getPreCommitListeners, getPreRollbackListeners
-
Constructor Details
-
PluginEntityContext
public PluginEntityContext(javax.persistence.EntityManagerFactory factory)
-
-
Method Details
-
getEm
public javax.persistence.EntityManager getEm()- Specified by:
getEm
in interfacede.xima.cmn.dao.interfaces.IBaseEntityContext
-
isOpen
public boolean isOpen()- Specified by:
isOpen
in interfacede.xima.cmn.dao.interfaces.IBaseEntityContext
-
close
public void close()- Specified by:
close
in interfaceAutoCloseable
- Specified by:
close
in interfaceCloseable
- Specified by:
close
in interfacede.xima.cmn.dao.interfaces.IBaseEntityContext
-