public class ServletContextApplicationContextInitializer extends Object implements org.springframework.context.ApplicationContextInitializer<org.springframework.web.context.ConfigurableWebApplicationContext>, org.springframework.core.Ordered
ApplicationContextInitializer
for setting the servlet context.Constructor and Description |
---|
ServletContextApplicationContextInitializer(ServletContext servletContext)
Create a new
ServletContextApplicationContextInitializer instance. |
ServletContextApplicationContextInitializer(ServletContext servletContext,
boolean addApplicationContextAttribute)
Create a new
ServletContextApplicationContextInitializer instance. |
Modifier and Type | Method and Description |
---|---|
int |
getOrder() |
void |
initialize(org.springframework.web.context.ConfigurableWebApplicationContext applicationContext) |
void |
setOrder(int order) |
public ServletContextApplicationContextInitializer(ServletContext servletContext)
ServletContextApplicationContextInitializer
instance.servletContext
- the servlet that should be ultimately set.public ServletContextApplicationContextInitializer(ServletContext servletContext, boolean addApplicationContextAttribute)
ServletContextApplicationContextInitializer
instance.servletContext
- the servlet that should be ultimately set.addApplicationContextAttribute
- if the ApplicationContext
should be
stored as an attribute in the ServletContext
public void setOrder(int order)
public int getOrder()
getOrder
in interface org.springframework.core.Ordered
public void initialize(org.springframework.web.context.ConfigurableWebApplicationContext applicationContext)
initialize
in interface org.springframework.context.ApplicationContextInitializer<org.springframework.web.context.ConfigurableWebApplicationContext>
Copyright © 2017 Pivotal Software, Inc.. All rights reserved.