spring----contextConfigLocation
2015-09-30 11:06
489 查看
web.xml里的contextConfigLocation参数定义了要装入的 Spring 配置文件。
xml代码类似如下:
这里是给ContextLoaderListener指定要加载的xml,会去加载相应的xml,
容器对于web.xml的加载过程是context-param >> listener >> fileter >> servlet。
xml代码类似如下:
<listener> <listener-class>org.springframework.web.context.ContextLoaderListener</listener-class> </listener> <context-param> <param-name>contextConfigLocation</param-name> <param-value> /WEB-INF/spring/applicationContext*.xml </param-value> </context-param>
这里是给ContextLoaderListener指定要加载的xml,会去加载相应的xml,
容器对于web.xml的加载过程是context-param >> listener >> fileter >> servlet。
相关文章推荐
- Java DFA算法实现敏感词过滤
- java并发编程学习:如何等待多个线程执行完成后再继续后续处理(synchronized、join、FutureTask、CyclicBarrier)
- java08:成绩管理系统
- Java抽象类和接口的区别
- java实例变量初始化
- Protobuf在Java中的使用
- Java制作证书的工具keytool用法总结
- java jdbc连接数据库的完整步骤
- Maven .m2\repository\jdk\tools\1.7 missing
- Java对象的序列化和反序列化
- 常用java代理方法
- java Junit 测试
- Eclipse配色
- test9.10
- 版本问题 Java:Unsupported major.minor version 51.0 (unable to load class . . .
- Java 输入输出流
- 自制JAVA容器图
- Java Exception
- spring事务隔离级别和传播行为
- test9.9