The Spring Framework

org.springframework.orm.jpa
Class EntityManagerHolder

java.lang.Object
  extended by org.springframework.transaction.support.ResourceHolderSupport
      extended by org.springframework.orm.jpa.EntityManagerHolder

public class EntityManagerHolder
extends ResourceHolderSupport

Holder wrapping a JPA EntityManager. JpaTransactionManager binds instances of this class to the thread, for a given EntityManagerFactory.

Note: This is an SPI class, not intended to be used by applications.

Since:
2.0
Author:
Juergen Hoeller
See Also:
JpaTransactionManager, EntityManagerFactoryUtils

Constructor Summary
EntityManagerHolder(javax.persistence.EntityManager entityManager)
           
 
Method Summary
 javax.persistence.EntityManager getEntityManager()
           
 
Methods inherited from class org.springframework.transaction.support.ResourceHolderSupport
clear, getDeadline, getTimeToLiveInMillis, getTimeToLiveInSeconds, hasTimeout, isOpen, isRollbackOnly, isSynchronizedWithTransaction, released, requested, reset, setRollbackOnly, setSynchronizedWithTransaction, setTimeoutInMillis, setTimeoutInSeconds
 
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
 

Constructor Detail

EntityManagerHolder

public EntityManagerHolder(javax.persistence.EntityManager entityManager)
Method Detail

getEntityManager

public javax.persistence.EntityManager getEntityManager()

The Spring Framework

Copyright © 2002-2007 The Spring Framework.