Code example for Properties

Methods: size

0
	} 
	 
	protected static void initializeEntityManagerFactory(String persistenceUnitName, Properties properties) {
		try { 
			if (emf == null)
				if (properties==null || properties.size()==0) {
					emf = Persistence.createEntityManagerFactory(persistenceUnitName);
				} else { 
					emf = Persistence.createEntityManagerFactory(persistenceUnitName, properties);
				} 
		} 
		catch (Throwable t) {
			log.error("entityManagerFactory creation failed", t);
			throw new ExceptionInInitializerError(t);
		} 
		 
	} 
	 
}