Home » Spring-Framework-090522 » org.springframework » web » context » support » [javadoc | source]
org.springframework.web.context.support
public class: StaticWebApplicationContext [javadoc | source]
java.lang.Object
   org.springframework.core.io.DefaultResourceLoader
      org.springframework.context.support.AbstractApplicationContext
         org.springframework.context.support.GenericApplicationContext
            org.springframework.context.support.StaticApplicationContext
               org.springframework.web.context.support.StaticWebApplicationContext

All Implemented Interfaces:
    ThemeSource, ConfigurableWebApplicationContext, BeanDefinitionRegistry, ConfigurableApplicationContext, DisposableBean, ResourceLoader

Static org.springframework.web.context.WebApplicationContext implementation for testing. Not intended for use in production applications.

Implements the org.springframework.web.context.ConfigurableWebApplicationContext interface to allow for direct replacement of an XmlWebApplicationContext , despite not actually supporting external configuration files.

Interprets resource paths as servlet context resources, i.e. as paths beneath the web application root. Absolute paths, e.g. for files outside the web app root, can be accessed via "file:" URLs, as implemented by org.springframework.core.io.DefaultResourceLoader .

In addition to the special beans detected by org.springframework.context.support.AbstractApplicationContext , this class detects a bean of type org.springframework.ui.context.ThemeSource in the context, under the special bean name "themeSource".

Fields inherited from org.springframework.context.support.AbstractApplicationContext:
MESSAGE_SOURCE_BEAN_NAME,  APPLICATION_EVENT_MULTICASTER_BEAN_NAME,  logger
Constructor:
 public StaticWebApplicationContext() 
Method from org.springframework.web.context.support.StaticWebApplicationContext Summary:
getConfigLocations,   getNamespace,   getResourceByPath,   getResourcePatternResolver,   getServletConfig,   getServletContext,   getTheme,   onRefresh,   postProcessBeanFactory,   setConfigLocation,   setConfigLocations,   setNamespace,   setServletConfig,   setServletContext
Methods from org.springframework.context.support.StaticApplicationContext:
addMessage,   getStaticMessageSource,   registerPrototype,   registerPrototype,   registerSingleton,   registerSingleton
Methods from org.springframework.context.support.GenericApplicationContext:
closeBeanFactory,   getBeanDefinition,   getBeanFactory,   getDefaultListableBeanFactory,   getResource,   getResources,   isAlias,   isBeanNameInUse,   refreshBeanFactory,   registerAlias,   registerBeanDefinition,   removeAlias,   removeBeanDefinition,   setParent,   setResourceLoader
Methods from org.springframework.context.support.AbstractApplicationContext:
addApplicationListener,   addBeanFactoryPostProcessor,   addListener,   cancelRefresh,   close,   closeBeanFactory,   containsBean,   containsBeanDefinition,   containsLocalBean,   destroy,   destroyBeans,   doClose,   finishBeanFactoryInitialization,   finishRefresh,   getAliases,   getApplicationListeners,   getAutowireCapableBeanFactory,   getBean,   getBean,   getBean,   getBeanDefinitionCount,   getBeanDefinitionNames,   getBeanFactory,   getBeanFactoryPostProcessors,   getBeanNamesForType,   getBeanNamesForType,   getBeansOfType,   getBeansOfType,   getDisplayName,   getId,   getInternalParentBeanFactory,   getInternalParentMessageSource,   getMessage,   getMessage,   getMessage,   getParent,   getParentBeanFactory,   getResourcePatternResolver,   getResources,   getStartupDate,   getType,   initApplicationEventMulticaster,   initMessageSource,   invokeBeanFactoryPostProcessors,   isActive,   isPrototype,   isRunning,   isSingleton,   isTypeMatch,   obtainFreshBeanFactory,   onClose,   onRefresh,   postProcessBeanFactory,   prepareBeanFactory,   prepareRefresh,   publishEvent,   refresh,   refreshBeanFactory,   registerBeanPostProcessors,   registerListeners,   registerShutdownHook,   setDisplayName,   setId,   setParent,   start,   stop,   toString
Methods from org.springframework.core.io.DefaultResourceLoader:
getClassLoader,   getResource,   getResourceByPath,   setClassLoader
Methods from java.lang.Object:
clone,   equals,   finalize,   getClass,   hashCode,   notify,   notifyAll,   toString,   wait,   wait,   wait
Method from org.springframework.web.context.support.StaticWebApplicationContext Detail:
 public String[] getConfigLocations() 
 public String getNamespace() 
 protected Resource getResourceByPath(String path) 
    This implementation supports file paths beneath the root of the ServletContext.
 protected ResourcePatternResolver getResourcePatternResolver() 
    This implementation supports pattern matching in unexpanded WARs too.
 public ServletConfig getServletConfig() 
 public ServletContext getServletContext() 
 public Theme getTheme(String themeName) 
 protected  void onRefresh() 
    Initialize the theme capability.
 protected  void postProcessBeanFactory(ConfigurableListableBeanFactory beanFactory) 
 public  void setConfigLocation(String configLocation) 
 public  void setConfigLocations(String[] configLocations) 
 public  void setNamespace(String namespace) 
 public  void setServletConfig(ServletConfig servletConfig) 
 public  void setServletContext(ServletContext servletContext) 
    Set the ServletContext that this WebApplicationContext runs in.