org.unitils.orm.hibernate.util
Class HibernateSessionFactoryLoader

java.lang.Object
  extended by org.unitils.orm.hibernate.util.HibernateSessionFactoryLoader
All Implemented Interfaces:
OrmPersistenceUnitLoader<org.hibernate.SessionFactory,org.hibernate.cfg.Configuration,OrmConfig>

public class HibernateSessionFactoryLoader
extends Object
implements OrmPersistenceUnitLoader<org.hibernate.SessionFactory,org.hibernate.cfg.Configuration,OrmConfig>


Field Summary
protected  String databaseName
           
 
Constructor Summary
HibernateSessionFactoryLoader(String databaseName)
           
 
Method Summary
protected  org.springframework.orm.hibernate3.LocalSessionFactoryBean createSessionFactoryBean(Object testObject, OrmConfig entityManagerConfig)
           
protected  Class<? extends org.hibernate.cfg.Configuration> getConfigurationObjectClass()
           
 ConfiguredOrmPersistenceUnit<org.hibernate.SessionFactory,org.hibernate.cfg.Configuration> getConfiguredOrmPersistenceUnit(Object testObject, OrmConfig entityManagerConfig)
           
protected  DatabaseModule getDatabaseModule()
           
protected  DataSource getDataSource()
           
protected  HibernateModule getHibernateModule()
           
 
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
 

Field Detail

databaseName

protected String databaseName
Constructor Detail

HibernateSessionFactoryLoader

public HibernateSessionFactoryLoader(String databaseName)
Parameters:
databaseName -
Method Detail

getConfiguredOrmPersistenceUnit

public ConfiguredOrmPersistenceUnit<org.hibernate.SessionFactory,org.hibernate.cfg.Configuration> getConfiguredOrmPersistenceUnit(Object testObject,
                                                                                                                                  OrmConfig entityManagerConfig)
Specified by:
getConfiguredOrmPersistenceUnit in interface OrmPersistenceUnitLoader<org.hibernate.SessionFactory,org.hibernate.cfg.Configuration,OrmConfig>
Parameters:
testObject - The test object, not null
entityManagerConfig - The persistence unit configuration, not null
Returns:
An instance of ConfiguredOrmPersistenceUnit that wraps the persistence unit and an implementation specific configuration object

createSessionFactoryBean

protected org.springframework.orm.hibernate3.LocalSessionFactoryBean createSessionFactoryBean(Object testObject,
                                                                                              OrmConfig entityManagerConfig)

getConfigurationObjectClass

protected Class<? extends org.hibernate.cfg.Configuration> getConfigurationObjectClass()

getDataSource

protected DataSource getDataSource()

getDatabaseModule

protected DatabaseModule getDatabaseModule()

getHibernateModule

protected HibernateModule getHibernateModule()


Copyright © 2014. All Rights Reserved.