|
||||||||||
| PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
| SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD | |||||||||
java.lang.Objectcom.caucho.amber.manager.EntityManagerTransactionProxy
public class EntityManagerTransactionProxy
The @PersistenceContext, container managed entity manager proxy, used for third-party providers.
| Constructor Summary | |
|---|---|
EntityManagerTransactionProxy(AmberContainer amber,
java.lang.String unitName,
java.util.Map props)
|
|
| Method Summary | ||
|---|---|---|
void |
clear()
Clears the manager. |
|
void |
clear(java.lang.Object entity)
Clears the entity |
|
void |
close()
Clears the manager. |
|
boolean |
contains(java.lang.Object entity)
Returns true if the entity belongs to the current context. |
|
Query |
createNamedQuery(java.lang.String sql)
Creates an instance of the named query |
|
Query |
createNativeQuery(java.lang.String sql)
Creates a query. |
|
Query |
createNativeQuery(java.lang.String sql,
java.lang.Class retType)
Creates a query. |
|
Query |
createNativeQuery(java.lang.String sql,
java.lang.String map)
Creates a query. |
|
Query |
createQuery(java.lang.String sql)
Creates a query. |
|
|
find(java.lang.Class<T> entityClass,
java.lang.Object primaryKey)
Find by the primary key. |
|
|
find(java.lang.Class<T> entityCLass,
java.lang.Object primaryKey,
LockModeType lockMode)
Find based on the primary key. |
|
|
find(java.lang.Class<T> entityCLass,
java.lang.Object primaryKey,
LockModeType lockMode,
java.util.Map properties)
Find based on the primary key. |
|
void |
flush()
Synchronize with the database. |
|
java.lang.Object |
getDelegate()
Gets the delegate. |
|
EntityManagerFactory |
getEntityManagerFactory()
Returns the owning factory |
|
FlushModeType |
getFlushMode()
Returns the flush mode. |
|
LockModeType |
getLockMode(java.lang.Object entity)
Returns the lock mode for the entity |
|
java.util.Map |
getProperties()
Returns the properties for the entity manager |
|
|
getReference(java.lang.Class<T> entityClass,
java.lang.Object primaryKey)
Find by the primary key. |
|
java.util.Set<java.lang.String> |
getSupportedProperties()
Returns the supported properties for the entity manager |
|
EntityTransaction |
getTransaction()
Returns the entity manager transaction. |
|
boolean |
isOpen()
Returns true if open. |
|
void |
joinTransaction()
Joins the transaction. |
|
void |
lock(java.lang.Object entity,
LockModeType lockMode)
Locks the object. |
|
void |
lock(java.lang.Object entity,
LockModeType lockMode,
java.util.Map properties)
Sets the lock mode for an entity. |
|
|
merge(T entity)
Merges the state of the entity into the current context. |
|
void |
persist(java.lang.Object entity)
Makes the instance managed. |
|
void |
refresh(java.lang.Object entity)
Refresh the state of the instance from the database. |
|
void |
refresh(java.lang.Object entity,
LockModeType lockMode)
Update the state of the instance from the database. |
|
void |
refresh(java.lang.Object entity,
LockModeType lockMode,
java.util.Map properties)
Update the state of the instance from the database. |
|
void |
remove(java.lang.Object entity)
Remove the instance. |
|
void |
setExtended(boolean isExtended)
Sets the extended type. |
|
void |
setFlushMode(FlushModeType mode)
Sets the flush mode. |
|
void |
setSerializationHandle(java.lang.Object handle)
Serialization handle |
|
java.lang.String |
toString()
|
|
| Methods inherited from class java.lang.Object |
|---|
clone, equals, finalize, getClass, hashCode, notify, notifyAll, wait, wait, wait |
| Constructor Detail |
|---|
public EntityManagerTransactionProxy(AmberContainer amber,
java.lang.String unitName,
java.util.Map props)
| Method Detail |
|---|
public void persist(java.lang.Object entity)
persist in interface EntityManagerpublic <T> T merge(T entity)
merge in interface EntityManagerpublic void remove(java.lang.Object entity)
remove in interface EntityManager
public <T> T find(java.lang.Class<T> entityClass,
java.lang.Object primaryKey)
find in interface EntityManager
public <T> T getReference(java.lang.Class<T> entityClass,
java.lang.Object primaryKey)
getReference in interface EntityManagerpublic FlushModeType getFlushMode()
getFlushMode in interface EntityManagerpublic void setFlushMode(FlushModeType mode)
setFlushMode in interface EntityManagerpublic void setExtended(boolean isExtended)
public void lock(java.lang.Object entity,
LockModeType lockMode)
lock in interface EntityManagerpublic void clear()
clear in interface EntityManagerpublic void flush()
flush in interface EntityManagerpublic void joinTransaction()
joinTransaction in interface EntityManagerpublic java.lang.Object getDelegate()
getDelegate in interface EntityManagerpublic void close()
close in interface EntityManagerpublic Query createQuery(java.lang.String sql)
createQuery in interface EntityManagerpublic Query createNamedQuery(java.lang.String sql)
createNamedQuery in interface EntityManagerpublic Query createNativeQuery(java.lang.String sql)
createNativeQuery in interface EntityManager
public Query createNativeQuery(java.lang.String sql,
java.lang.String map)
createNativeQuery in interface EntityManager
public Query createNativeQuery(java.lang.String sql,
java.lang.Class retType)
createNativeQuery in interface EntityManagerpublic void refresh(java.lang.Object entity)
refresh in interface EntityManagerpublic boolean contains(java.lang.Object entity)
contains in interface EntityManagerpublic EntityTransaction getTransaction()
getTransaction in interface EntityManagerpublic boolean isOpen()
isOpen in interface EntityManager
public <T> T find(java.lang.Class<T> entityCLass,
java.lang.Object primaryKey,
LockModeType lockMode)
find in interface EntityManager
public <T> T find(java.lang.Class<T> entityCLass,
java.lang.Object primaryKey,
LockModeType lockMode,
java.util.Map properties)
find in interface EntityManager
public void lock(java.lang.Object entity,
LockModeType lockMode,
java.util.Map properties)
lock in interface EntityManager
public void refresh(java.lang.Object entity,
LockModeType lockMode)
refresh in interface EntityManager
public void refresh(java.lang.Object entity,
LockModeType lockMode,
java.util.Map properties)
refresh in interface EntityManagerpublic void clear(java.lang.Object entity)
clear in interface EntityManagerpublic LockModeType getLockMode(java.lang.Object entity)
getLockMode in interface EntityManagerpublic java.util.Map getProperties()
getProperties in interface EntityManagerpublic java.util.Set<java.lang.String> getSupportedProperties()
getSupportedProperties in interface EntityManagerpublic EntityManagerFactory getEntityManagerFactory()
getEntityManagerFactory in interface EntityManagerpublic void setSerializationHandle(java.lang.Object handle)
setSerializationHandle in interface HandleAwarepublic java.lang.String toString()
toString in class java.lang.Object
|
||||||||||
| PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
| SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD | |||||||||