spring-web

org.springframework.web.context.support
Class ServletContextAwareProcessor

java.lang.Object
  extended by org.springframework.web.context.support.ServletContextAwareProcessor
All Implemented Interfaces:
org.springframework.beans.factory.config.BeanPostProcessor

public class ServletContextAwareProcessor
extends java.lang.Object
implements org.springframework.beans.factory.config.BeanPostProcessor

BeanPostProcessor implementation that passes the ServletContext to beans that implement the ServletContextAware interface.

Web application contexts will automatically register this with their underlying bean factory. Applications do not use this directly.

Since:
12.03.2004
Author:
Juergen Hoeller
See Also:
ServletContextAware, AbstractRefreshableWebApplicationContext.postProcessBeanFactory(org.springframework.beans.factory.config.ConfigurableListableBeanFactory)

Constructor Summary
ServletContextAwareProcessor(javax.servlet.ServletConfig servletConfig)
          Create a new ServletContextAwareProcessor for the given config.
ServletContextAwareProcessor(javax.servlet.ServletContext servletContext)
          Create a new ServletContextAwareProcessor for the given context.
ServletContextAwareProcessor(javax.servlet.ServletContext servletContext, javax.servlet.ServletConfig servletConfig)
          Create a new ServletContextAwareProcessor for the given context and config.
 
Method Summary
 java.lang.Object postProcessAfterInitialization(java.lang.Object bean, java.lang.String beanName)
           
 java.lang.Object postProcessBeforeInitialization(java.lang.Object bean, java.lang.String beanName)
           
 
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
 

Constructor Detail

ServletContextAwareProcessor

public ServletContextAwareProcessor(javax.servlet.ServletContext servletContext)
Create a new ServletContextAwareProcessor for the given context.


ServletContextAwareProcessor

public ServletContextAwareProcessor(javax.servlet.ServletConfig servletConfig)
Create a new ServletContextAwareProcessor for the given config.


ServletContextAwareProcessor

public ServletContextAwareProcessor(javax.servlet.ServletContext servletContext,
                                    javax.servlet.ServletConfig servletConfig)
Create a new ServletContextAwareProcessor for the given context and config.

Method Detail

postProcessBeforeInitialization

public java.lang.Object postProcessBeforeInitialization(java.lang.Object bean,
                                                        java.lang.String beanName)
                                                 throws org.springframework.beans.BeansException
Specified by:
postProcessBeforeInitialization in interface org.springframework.beans.factory.config.BeanPostProcessor
Throws:
org.springframework.beans.BeansException

postProcessAfterInitialization

public java.lang.Object postProcessAfterInitialization(java.lang.Object bean,
                                                       java.lang.String beanName)
Specified by:
postProcessAfterInitialization in interface org.springframework.beans.factory.config.BeanPostProcessor

spring-web