如何在web环境中配置applicationContext.xml文件?

2014-11-06 17:30:06 · 作者: · 浏览: 26



org.springframework.web.context.ContextLoaderListener


或:

context


org.springframework.web.context.ContextLoaderServlet

1

通过如下方法取出applicationContext实例:
ApplicationContext ac=WebApplicationContextUtils.getWebApplicationContext(this.getServletContext);