读书人

Spring里头applicationContext.xml文件

发布时间: 2012-09-11 10:49:04 作者: rapoo

Spring里面applicationContext.xml文件能不能改成其他文件名?
ContextLoaderListener是一个ServletContextListener, 它在你的web应用启动的时候初始化。缺省情况下, 它会在WEB-INF/applicationContext.xml文件找Spring的配置。 你可以通过定义一个<context-param>元素名字为”contextConfigLocation”来改变Spring配置文件的位置。示例如下:

读书人网 >XML SOAP

热点推荐