Package org.openxava.jpa.impl
Class EntityManagerDecorator
- java.lang.Object
-
- org.openxava.jpa.impl.EntityManagerDecorator
-
- All Implemented Interfaces:
javax.persistence.EntityManager
public class EntityManagerDecorator extends java.lang.Object implements javax.persistence.EntityManager
- Author:
- Federico Alcantara
-
-
Constructor Summary
Constructors Constructor Description EntityManagerDecorator(javax.persistence.EntityManager unDecoratedManager)
Constructor for attaching decoration to EntityManager
-
Method Summary
All Methods Instance Methods Concrete Methods Modifier and Type Method Description void
clear()
void
close()
boolean
contains(java.lang.Object arg0)
<T> javax.persistence.EntityGraph<T>
createEntityGraph(java.lang.Class<T> arg0)
javax.persistence.EntityGraph<?>
createEntityGraph(java.lang.String arg0)
javax.persistence.Query
createNamedQuery(java.lang.String arg0)
<T> javax.persistence.TypedQuery<T>
createNamedQuery(java.lang.String arg0, java.lang.Class<T> arg1)
javax.persistence.StoredProcedureQuery
createNamedStoredProcedureQuery(java.lang.String arg0)
javax.persistence.Query
createNativeQuery(java.lang.String arg0)
javax.persistence.Query
createNativeQuery(java.lang.String arg0, java.lang.Class arg1)
javax.persistence.Query
createNativeQuery(java.lang.String arg0, java.lang.String arg1)
javax.persistence.Query
createQuery(java.lang.String arg0)
<T> javax.persistence.TypedQuery<T>
createQuery(java.lang.String arg0, java.lang.Class<T> arg1)
javax.persistence.Query
createQuery(javax.persistence.criteria.CriteriaDelete arg0)
<T> javax.persistence.TypedQuery<T>
createQuery(javax.persistence.criteria.CriteriaQuery<T> arg0)
javax.persistence.Query
createQuery(javax.persistence.criteria.CriteriaUpdate arg0)
javax.persistence.StoredProcedureQuery
createStoredProcedureQuery(java.lang.String arg0)
javax.persistence.StoredProcedureQuery
createStoredProcedureQuery(java.lang.String arg0, java.lang.Class... arg1)
javax.persistence.StoredProcedureQuery
createStoredProcedureQuery(java.lang.String arg0, java.lang.String... arg1)
void
detach(java.lang.Object arg0)
<T> T
find(java.lang.Class<T> arg0, java.lang.Object arg1)
<T> T
find(java.lang.Class<T> arg0, java.lang.Object arg1, java.util.Map<java.lang.String,java.lang.Object> arg2)
<T> T
find(java.lang.Class<T> arg0, java.lang.Object arg1, javax.persistence.LockModeType arg2)
<T> T
find(java.lang.Class<T> arg0, java.lang.Object arg1, javax.persistence.LockModeType arg2, java.util.Map<java.lang.String,java.lang.Object> arg3)
void
flush()
javax.persistence.criteria.CriteriaBuilder
getCriteriaBuilder()
java.lang.Object
getDelegate()
javax.persistence.EntityGraph<?>
getEntityGraph(java.lang.String arg0)
<T> java.util.List<javax.persistence.EntityGraph<? super T>>
getEntityGraphs(java.lang.Class<T> arg0)
javax.persistence.EntityManagerFactory
getEntityManagerFactory()
javax.persistence.FlushModeType
getFlushMode()
javax.persistence.LockModeType
getLockMode(java.lang.Object arg0)
javax.persistence.metamodel.Metamodel
getMetamodel()
java.util.Map<java.lang.String,java.lang.Object>
getProperties()
<T> T
getReference(java.lang.Class<T> arg0, java.lang.Object arg1)
javax.persistence.EntityTransaction
getTransaction()
boolean
isJoinedToTransaction()
boolean
isOpen()
void
joinTransaction()
void
lock(java.lang.Object arg0, javax.persistence.LockModeType arg1)
void
lock(java.lang.Object arg0, javax.persistence.LockModeType arg1, java.util.Map<java.lang.String,java.lang.Object> arg2)
<T> T
merge(T arg0)
void
persist(java.lang.Object object)
Before and after persisting an object the PreCreate and PostCreate call backs found in the object are executed.void
refresh(java.lang.Object arg0)
void
refresh(java.lang.Object arg0, java.util.Map<java.lang.String,java.lang.Object> arg1)
void
refresh(java.lang.Object arg0, javax.persistence.LockModeType arg1)
void
refresh(java.lang.Object arg0, javax.persistence.LockModeType arg1, java.util.Map<java.lang.String,java.lang.Object> arg2)
void
remove(java.lang.Object arg0)
Before removing an object the PreDelete call backs encountered in the object are executed.void
setFlushMode(javax.persistence.FlushModeType arg0)
void
setProperty(java.lang.String arg0, java.lang.Object arg1)
<T> T
unwrap(java.lang.Class<T> arg0)
-
-
-
Method Detail
-
persist
public void persist(java.lang.Object object)
Before and after persisting an object the PreCreate and PostCreate call backs found in the object are executed. These calls occurs within a transaction.- Specified by:
persist
in interfacejavax.persistence.EntityManager
- Parameters:
object
- Object to be persisted
-
remove
public void remove(java.lang.Object arg0)
Before removing an object the PreDelete call backs encountered in the object are executed. These calls occurs within a transaction.- Specified by:
remove
in interfacejavax.persistence.EntityManager
- Parameters:
arg0
- Object to be removed
-
clear
public void clear()
- Specified by:
clear
in interfacejavax.persistence.EntityManager
-
close
public void close()
- Specified by:
close
in interfacejavax.persistence.EntityManager
-
contains
public boolean contains(java.lang.Object arg0)
- Specified by:
contains
in interfacejavax.persistence.EntityManager
-
createNamedQuery
public javax.persistence.Query createNamedQuery(java.lang.String arg0)
- Specified by:
createNamedQuery
in interfacejavax.persistence.EntityManager
-
createNamedQuery
public <T> javax.persistence.TypedQuery<T> createNamedQuery(java.lang.String arg0, java.lang.Class<T> arg1)
- Specified by:
createNamedQuery
in interfacejavax.persistence.EntityManager
-
createNativeQuery
public javax.persistence.Query createNativeQuery(java.lang.String arg0)
- Specified by:
createNativeQuery
in interfacejavax.persistence.EntityManager
-
createNativeQuery
public javax.persistence.Query createNativeQuery(java.lang.String arg0, java.lang.Class arg1)
- Specified by:
createNativeQuery
in interfacejavax.persistence.EntityManager
-
createNativeQuery
public javax.persistence.Query createNativeQuery(java.lang.String arg0, java.lang.String arg1)
- Specified by:
createNativeQuery
in interfacejavax.persistence.EntityManager
-
createQuery
public javax.persistence.Query createQuery(java.lang.String arg0)
- Specified by:
createQuery
in interfacejavax.persistence.EntityManager
-
createQuery
public <T> javax.persistence.TypedQuery<T> createQuery(javax.persistence.criteria.CriteriaQuery<T> arg0)
- Specified by:
createQuery
in interfacejavax.persistence.EntityManager
-
createQuery
public <T> javax.persistence.TypedQuery<T> createQuery(java.lang.String arg0, java.lang.Class<T> arg1)
- Specified by:
createQuery
in interfacejavax.persistence.EntityManager
-
detach
public void detach(java.lang.Object arg0)
- Specified by:
detach
in interfacejavax.persistence.EntityManager
-
find
public <T> T find(java.lang.Class<T> arg0, java.lang.Object arg1)
- Specified by:
find
in interfacejavax.persistence.EntityManager
-
find
public <T> T find(java.lang.Class<T> arg0, java.lang.Object arg1, java.util.Map<java.lang.String,java.lang.Object> arg2)
- Specified by:
find
in interfacejavax.persistence.EntityManager
-
find
public <T> T find(java.lang.Class<T> arg0, java.lang.Object arg1, javax.persistence.LockModeType arg2)
- Specified by:
find
in interfacejavax.persistence.EntityManager
-
find
public <T> T find(java.lang.Class<T> arg0, java.lang.Object arg1, javax.persistence.LockModeType arg2, java.util.Map<java.lang.String,java.lang.Object> arg3)
- Specified by:
find
in interfacejavax.persistence.EntityManager
-
flush
public void flush()
- Specified by:
flush
in interfacejavax.persistence.EntityManager
-
getCriteriaBuilder
public javax.persistence.criteria.CriteriaBuilder getCriteriaBuilder()
- Specified by:
getCriteriaBuilder
in interfacejavax.persistence.EntityManager
-
getDelegate
public java.lang.Object getDelegate()
- Specified by:
getDelegate
in interfacejavax.persistence.EntityManager
-
getEntityManagerFactory
public javax.persistence.EntityManagerFactory getEntityManagerFactory()
- Specified by:
getEntityManagerFactory
in interfacejavax.persistence.EntityManager
-
getFlushMode
public javax.persistence.FlushModeType getFlushMode()
- Specified by:
getFlushMode
in interfacejavax.persistence.EntityManager
-
getLockMode
public javax.persistence.LockModeType getLockMode(java.lang.Object arg0)
- Specified by:
getLockMode
in interfacejavax.persistence.EntityManager
-
getMetamodel
public javax.persistence.metamodel.Metamodel getMetamodel()
- Specified by:
getMetamodel
in interfacejavax.persistence.EntityManager
-
getProperties
public java.util.Map<java.lang.String,java.lang.Object> getProperties()
- Specified by:
getProperties
in interfacejavax.persistence.EntityManager
-
getReference
public <T> T getReference(java.lang.Class<T> arg0, java.lang.Object arg1)
- Specified by:
getReference
in interfacejavax.persistence.EntityManager
-
getTransaction
public javax.persistence.EntityTransaction getTransaction()
- Specified by:
getTransaction
in interfacejavax.persistence.EntityManager
-
isOpen
public boolean isOpen()
- Specified by:
isOpen
in interfacejavax.persistence.EntityManager
-
joinTransaction
public void joinTransaction()
- Specified by:
joinTransaction
in interfacejavax.persistence.EntityManager
-
lock
public void lock(java.lang.Object arg0, javax.persistence.LockModeType arg1)
- Specified by:
lock
in interfacejavax.persistence.EntityManager
-
lock
public void lock(java.lang.Object arg0, javax.persistence.LockModeType arg1, java.util.Map<java.lang.String,java.lang.Object> arg2)
- Specified by:
lock
in interfacejavax.persistence.EntityManager
-
merge
public <T> T merge(T arg0)
- Specified by:
merge
in interfacejavax.persistence.EntityManager
-
refresh
public void refresh(java.lang.Object arg0)
- Specified by:
refresh
in interfacejavax.persistence.EntityManager
-
refresh
public void refresh(java.lang.Object arg0, java.util.Map<java.lang.String,java.lang.Object> arg1)
- Specified by:
refresh
in interfacejavax.persistence.EntityManager
-
refresh
public void refresh(java.lang.Object arg0, javax.persistence.LockModeType arg1)
- Specified by:
refresh
in interfacejavax.persistence.EntityManager
-
refresh
public void refresh(java.lang.Object arg0, javax.persistence.LockModeType arg1, java.util.Map<java.lang.String,java.lang.Object> arg2)
- Specified by:
refresh
in interfacejavax.persistence.EntityManager
-
setFlushMode
public void setFlushMode(javax.persistence.FlushModeType arg0)
- Specified by:
setFlushMode
in interfacejavax.persistence.EntityManager
-
setProperty
public void setProperty(java.lang.String arg0, java.lang.Object arg1)
- Specified by:
setProperty
in interfacejavax.persistence.EntityManager
-
unwrap
public <T> T unwrap(java.lang.Class<T> arg0)
- Specified by:
unwrap
in interfacejavax.persistence.EntityManager
-
createEntityGraph
public <T> javax.persistence.EntityGraph<T> createEntityGraph(java.lang.Class<T> arg0)
- Specified by:
createEntityGraph
in interfacejavax.persistence.EntityManager
-
createEntityGraph
public javax.persistence.EntityGraph<?> createEntityGraph(java.lang.String arg0)
- Specified by:
createEntityGraph
in interfacejavax.persistence.EntityManager
-
createNamedStoredProcedureQuery
public javax.persistence.StoredProcedureQuery createNamedStoredProcedureQuery(java.lang.String arg0)
- Specified by:
createNamedStoredProcedureQuery
in interfacejavax.persistence.EntityManager
-
createQuery
public javax.persistence.Query createQuery(javax.persistence.criteria.CriteriaUpdate arg0)
- Specified by:
createQuery
in interfacejavax.persistence.EntityManager
-
createQuery
public javax.persistence.Query createQuery(javax.persistence.criteria.CriteriaDelete arg0)
- Specified by:
createQuery
in interfacejavax.persistence.EntityManager
-
createStoredProcedureQuery
public javax.persistence.StoredProcedureQuery createStoredProcedureQuery(java.lang.String arg0)
- Specified by:
createStoredProcedureQuery
in interfacejavax.persistence.EntityManager
-
createStoredProcedureQuery
public javax.persistence.StoredProcedureQuery createStoredProcedureQuery(java.lang.String arg0, java.lang.Class... arg1)
- Specified by:
createStoredProcedureQuery
in interfacejavax.persistence.EntityManager
-
createStoredProcedureQuery
public javax.persistence.StoredProcedureQuery createStoredProcedureQuery(java.lang.String arg0, java.lang.String... arg1)
- Specified by:
createStoredProcedureQuery
in interfacejavax.persistence.EntityManager
-
getEntityGraph
public javax.persistence.EntityGraph<?> getEntityGraph(java.lang.String arg0)
- Specified by:
getEntityGraph
in interfacejavax.persistence.EntityManager
-
getEntityGraphs
public <T> java.util.List<javax.persistence.EntityGraph<? super T>> getEntityGraphs(java.lang.Class<T> arg0)
- Specified by:
getEntityGraphs
in interfacejavax.persistence.EntityManager
-
isJoinedToTransaction
public boolean isJoinedToTransaction()
- Specified by:
isJoinedToTransaction
in interfacejavax.persistence.EntityManager
-
-