Tabnine Logo
HibernatePersistence.createEntityManagerFactory
Code IndexAdd Tabnine to your IDE (free)

How to use
createEntityManagerFactory
method
in
org.hibernate.ejb.HibernatePersistence

Best Java code snippets using org.hibernate.ejb.HibernatePersistence.createEntityManagerFactory (Showing top 3 results out of 315)

origin: uk.ac.ebi.intact.core/intact-core

public EntityManagerFactory createEntityManagerFactory(String emName, Map map) {
  if (log.isInfoEnabled()) log.info("Creating EntityManagerFactory: "+emName+" ("+map+")");
  HibernatePersistence hibernatePersistence = new HibernatePersistence();
  EntityManagerFactory emf = hibernatePersistence.createEntityManagerFactory(emName, map);
  return emf;
}
origin: uk.ac.ebi.intact.core/intact-core-readonly

public EntityManagerFactory createEntityManagerFactory(String emName, Map map) {
  if (log.isInfoEnabled()) log.info("Creating EntityManagerFactory: "+emName+" ("+map+")");
  HibernatePersistence hibernatePersistence = new HibernatePersistence();
  EntityManagerFactory emf = hibernatePersistence.createEntityManagerFactory(emName, map);
  return emf;
}
origin: org.artificer/artificer-repository-hibernate

private synchronized static EntityManager entityManager() throws Exception {
  if (entityManagerFactory == null) {
    // Pass in all hibernate.* settings from artificer.properties
    Map<String, Object> properties = ArtificerConfig.getConfigProperties("hibernate");
    if (properties.containsKey("hibernate.connection.url")) {
      // If a connection is used, we *cannot* rely on Hibernate's built-in connection pool.  Instead,
      // automatically set up HikariCP.
      initHikariCP(properties);
    }
    entityManagerFactory = new HibernatePersistence().createEntityManagerFactory(persistenceUnit, properties);
    EntityManager entityManager = entityManagerFactory.createEntityManager();
    initDDL(entityManager, properties);
    return entityManager;
  } else {
    return entityManagerFactory.createEntityManager();
  }
}
org.hibernate.ejbHibernatePersistencecreateEntityManagerFactory

Javadoc

Get an entity manager factory by its entity manager name, using the specified properties (they override any found in the peristence.xml file).

This is the form used in JSE environments.

Popular methods of HibernatePersistence

  • <init>
  • createContainerEntityManagerFactory
    Create an entity manager factory from the given persistence unit info, using the specified propertie
  • getProviderUtil

Popular in Java

  • Parsing JSON documents to java classes using gson
  • getSystemService (Context)
  • putExtra (Intent)
  • onCreateOptionsMenu (Activity)
  • URI (java.net)
    A Uniform Resource Identifier that identifies an abstract or physical resource, as specified by RFC
  • NumberFormat (java.text)
    The abstract base class for all number formats. This class provides the interface for formatting and
  • SimpleDateFormat (java.text)
    Formats and parses dates in a locale-sensitive manner. Formatting turns a Date into a String, and pa
  • SortedSet (java.util)
    SortedSet is a Set which iterates over its elements in a sorted order. The order is determined eithe
  • Base64 (org.apache.commons.codec.binary)
    Provides Base64 encoding and decoding as defined by RFC 2045.This class implements section 6.8. Base
  • DateTimeFormat (org.joda.time.format)
    Factory that creates instances of DateTimeFormatter from patterns and styles. Datetime formatting i
  • Top 12 Jupyter Notebook extensions
Tabnine Logo
  • Products

    Search for Java codeSearch for JavaScript code
  • IDE Plugins

    IntelliJ IDEAWebStormVisual StudioAndroid StudioEclipseVisual Studio CodePyCharmSublime TextPhpStormVimGoLandRubyMineEmacsJupyter NotebookJupyter LabRiderDataGripAppCode
  • Company

    About UsContact UsCareers
  • Resources

    FAQBlogTabnine AcademyTerms of usePrivacy policyJava Code IndexJavascript Code Index
Get Tabnine for your IDE now