Jump to: navigation, search

Difference between revisions of "EclipseLink/Examples/JPA/OutsideContainer"

(No difference)

Revision as of 15:51, 16 October 2007

Users may also use the EntityManager API outside the container by creating a EntityManagerFactory for a given persistence unit name and properties map (includes database information etc.)

EntityManagerFactory emf = Persistence.createEntityManagerFactory(persistenceUnitName, propertiesMap);
EntityManager em = emf.createEntityManager();