class path resource [spring.xml] cannot be opened because it does not exist
来源:互联网 发布:制作电影的软件 编辑:程序博客网 时间:2024/05/21 22:27
使用maven创建web工程,将spring配置文件applicationContext.xml放在src/resource下,用Myeclipse编译时提示class path resource [applicationContext.xml] cannot be opened because it does not exist错误。
web.xml配置的如下
<context-param>
<param-name>contextConfigLocation</param-name>
<param-value>classpath:applicationContext.xml</param-value>
</context-param>
是由于classpath不是指向resource路径,导致一直找不到文件。需要在classpath后面加个*,这样就解决问题了。
<context-param>
<param-name>contextConfigLocation</param-name>
<param-value>classpath*:applicationContext.xml</param-value>
</context-param>
阅读全文
0 0
- class path resource [spring.xml] cannot be opened because it does not exist
- Spring问题:class path resource [xxx.xml] cannot be opened because it does not exist
- class path resource [spring-mvc.xml] cannot be opened because it does not exist
- 关于class path resource [applicationContext.xml] cannot be opened because it does not exist
- class path resource [META-INF/xfire/services.xml] cannot be opened because it does not exist
- class path resource [applicationContext.xml] cannot be opened because it does not exist
- class path resource [applicationContext.xml] cannot be opened because it does not exist
- spring class path resource [jdbc.properties] cannot be opened because it does not exist
- class path resource [spring.xml] cannot be opened because it does no exist;
- IDEA中Spring配置错误:class path resource [.xml] cannot be opened because it does not exist
- java.io.FileNotFoundException: class path resource [spring.xml] cannot be opened because it does not
- java.io.FileNotFoundException: class path resource ..cannot be opened because it does not exist
- java.io.FileNotFoundException: class path resource [META-INF/xfire/services.xml] cannot be opened because it does not exist
- java.io.FileNotFoundException: class path resource [beans.xml] cannot be opened because it does not exist 解决方法
- eclipse项目报错怎么解决class path resource [beans.xml] cannot be opened because it does not exist
- Spring问题:class path resource [org.spring/applicationContext.xml] cannot be opened because it does no
- java.io.FileNotFoundException: class path resource [beans.xml] cannot be opened because it does not
- java.io.FileNotFoundException: class path resource [beans.xml] cannot be opened because it does not
- 通配符:?
- C++实现纸牌类,并发牌
- Java浮点类型(Double/Float)运算精度问题
- 传统复制常见错误及填坑方法
- Kconfig详解
- class path resource [spring.xml] cannot be opened because it does not exist
- 流媒体之rtsp篇
- c# new三种用法
- 120. Triangle
- 使用Eclipse构建Maven项目 (step-by-step)
- linux下vue热更新失败的解决方法
- 【PSI/SI学习系列】2.PSI/SI深入学习3——SI信息解析2(SDT, EIT, TDT,TOT)——神文004
- Spring学习(三)使用Spring容器创建bean
- 如何安装Qt 5.8.0 +mingw