org.codehaus.groovy.grails.plugins.springsecurity
Class GrailsWebApplicationObjectSupport

java.lang.Object
  extended by org.springframework.context.support.ApplicationObjectSupport
      extended by org.springframework.web.context.support.WebApplicationObjectSupport
          extended by org.codehaus.groovy.grails.plugins.springsecurity.GrailsWebApplicationObjectSupport
All Implemented Interfaces:
org.springframework.context.ApplicationContextAware, org.springframework.web.context.ServletContextAware

public abstract class GrailsWebApplicationObjectSupport
extends org.springframework.web.context.support.WebApplicationObjectSupport

Grails Web Application Object Support.

Author:
T.Yamamoto, Burt Beckwith

Nested Class Summary
static class GrailsWebApplicationObjectSupport.SessionContainer
          Holds the session created or existing session and a flag indicating whether it was existing (so we know whether to close it or not).
 
Field Summary
 
Fields inherited from class org.springframework.context.support.ApplicationObjectSupport
logger
 
Constructor Summary
GrailsWebApplicationObjectSupport()
           
 
Method Summary
protected  void releaseSession(GrailsWebApplicationObjectSupport.SessionContainer session)
          Release Session.
 void setSessionFactory(org.hibernate.SessionFactory sessionFactory)
          Dependency injection for Hibernate session factory.
protected  GrailsWebApplicationObjectSupport.SessionContainer setUpSession()
          Set up hibernate session.
 
Methods inherited from class org.springframework.web.context.support.WebApplicationObjectSupport
getServletContext, getTempDir, getWebApplicationContext, initApplicationContext, initServletContext, isContextRequired, setServletContext
 
Methods inherited from class org.springframework.context.support.ApplicationObjectSupport
getApplicationContext, getMessageSourceAccessor, initApplicationContext, requiredContextClass, setApplicationContext
 
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
 

Constructor Detail

GrailsWebApplicationObjectSupport

public GrailsWebApplicationObjectSupport()
Method Detail

setSessionFactory

public void setSessionFactory(org.hibernate.SessionFactory sessionFactory)
Dependency injection for Hibernate session factory.

Parameters:
sessionFactory - the factory

setUpSession

protected GrailsWebApplicationObjectSupport.SessionContainer setUpSession()
Set up hibernate session.

Returns:
the session container, which holds the session and a boolean indicating if the session was pre-existing

releaseSession

protected void releaseSession(GrailsWebApplicationObjectSupport.SessionContainer session)
Release Session.