Skip navigation links
oracle.toplink.sessions.entitymanager
Class Persistence
java.lang.Object
oracle.toplink.sessions.entitymanager.Persistence
- public class Persistence
- extends java.lang.Object
Bootstrap class that provides access to an EntityManagerFactory
, from which EntityManager
references can be obtained.
Methods inherited from class java.lang.Object |
equals, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait |
PROVIDER_NAME
public static final java.lang.String PROVIDER_NAME
- Symbolic constant used by calls to
createEntityManagerFactory(java.util.Map)
methods to look up the implementation to load. This is set to "javax.persistence.provider".
- See Also:
- Constant Field Values
Persistence
public Persistence()
createEntityManagerFactory
public static EntityManagerFactory createEntityManagerFactory(java.util.Map m)
- Create an
EntityManagerFactory
. This looks through the following locations for a key called "javax.persistence.provider" that identifies which implementation should be created.
- contents of the Map parameter to this method call.
- applet environment
- system environment
- the contents of persistence.properties, as loaded by a call to
ClassLoader.getResourceAsStream(java.lang.String)
.
Note: we can steal some good copy from the javax.naming.Context and InitialContext JavaDocs, which outline similar rules for locating environment settings.
createEntityManagerFactory
public static EntityManagerFactory createEntityManagerFactory()
- Create an
EntityManagerFactory
. This uses the same heuristics as createEntityManagerFactory(java.util.Map)
, except that no invocation-specific information is used here.
Skip navigation links