星空网 > 软件开发 > Java

错误:找不到类org.springframework.web.context.ContextLoaderListener

 

严重: Error configuring application listener of class org.springframework.web.context.ContextLoaderListener
java.lang.ClassNotFoundException: org.springframework.web.context.ContextLoaderListener

错误:找不到类org.springframework.web.context.ContextLoaderListener

Java虚拟机是根据Java ClassLoader(类加载器)决定如何加载Class。 
系统默认提供了3个ClassLoader 
Root ClassLoader,ClassPath Loader,Ext ClassLoader 
我们也可以编写自己的ClassLoader,去加载特定环境下的Jar文件。 
能不能加载Jar,加载哪里的Jar,是由ClassLoader决定的。 

问题: 导入的仅仅是jar包的引用,例如在eclipse中通过build path加进user lib……(类似快捷方式) 
这种在Java Application中没问题,但在web Application中可能会出现找不到类的异常。 
在WEB Application中jar包最好放在webroot或webcontent下的lib文件夹内,特别是

解决:1.jar包放在webroot或webcontent下的lib文件夹内

   2. 右击项目名称-Properties--Deployment Assembly--右边点击ADD-Java Build path entries --添加自定义的user-lib

错误:找不到类org.springframework.web.context.ContextLoaderListener

 

错误:找不到类org.springframework.web.context.ContextLoaderListener错误:找不到类org.springframework.web.context.ContextLoaderListener




原标题:错误:找不到类org.springframework.web.context.ContextLoaderListener

关键词:Spring

*特别声明:以上内容来自于网络收集,著作权属原作者所有,如有侵权,请联系我们: admin#shaoqun.com (#换成@)。
相关文章
我的浏览记录
最新相关资讯
海外公司注册 | 跨境电商服务平台 | 深圳旅行社 | 东南亚物流