|
Groovy Documentation | |||||||
FRAMES NO FRAMES | ||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |
java.lang.Object org.springframework.orm.hibernate3.LocalSessionFactoryBean org.codehaus.groovy.grails.orm.hibernate.ConfigurableLocalSessionFactoryBean
public class ConfigurableLocalSessionFactoryBean extends LocalSessionFactoryBean
A SessionFactory bean that allows the configuration class to be changed and customise for usage within Grails.
Method Summary | |
---|---|
void
|
destroy()
|
GrailsApplication
|
getGrailsApplication()
@return Returns the grailsApplication. |
protected Configuration
|
newConfiguration()
Overrides default behaviour to allow for a configurable configuration class. |
protected SessionFactory
|
newSessionFactory(Configuration config)
|
protected void
|
postProcessConfiguration(Configuration config)
Merge HibernateEventListeners with the default ones |
void
|
setApplicationContext(ApplicationContext applicationContext)
|
void
|
setClassLoader(java.lang.ClassLoader classLoader)
|
void
|
setConfigClass(java.lang.Class configClass)
Sets the class to be used for Hibernate Configuration |
void
|
setCurrentSessionContextClass(java.lang.Class currentSessionContextClass)
Sets class to be used for the Hibernate CurrentSessionContext |
void
|
setGrailsApplication(GrailsApplication grailsApplication)
@param grailsApplication The grailsApplication to set. |
void
|
setHibernateEventListeners(HibernateEventListeners listeners)
|
Method Detail |
---|
@Override public void destroy()
public GrailsApplication getGrailsApplication()
@Override protected Configuration newConfiguration()
@Override protected SessionFactory newSessionFactory(Configuration config)
@Override protected void postProcessConfiguration(Configuration config)
public void setApplicationContext(ApplicationContext applicationContext)
public void setClassLoader(java.lang.ClassLoader classLoader)
public void setConfigClass(java.lang.Class configClass)
configClass
- A subclass of the Hibernate Configuration class
public void setCurrentSessionContextClass(java.lang.Class currentSessionContextClass)
currentSessionContextClass
- An implementation of the CurrentSessionContext interface
public void setGrailsApplication(GrailsApplication grailsApplication)
grailsApplication
- The grailsApplication to set.
public void setHibernateEventListeners(HibernateEventListeners listeners)
Groovy Documentation