spring配置,求问applicationContext.xml扫描问题

J2EE 码拜 9年前 (2015-09-30) 1083次浏览

1:<context:component-scan base-package=”org.xx” />

2:<util:properties id=”dbParams” location=”classpath:db.properties”>
</util:properties>
Multiple annotations found at this line:
– schema_reference.4: Failed to read schema document “”http://www.springframework.org/schema/context/spring
 context-3.2.xsd””, because 1) could not find the document; 2) the document could not be read; 3) the root element of the document is 
 not <xsd:schema>.
– cvc-complex-type.2.4.c: The matching wildcard is strict, but no declaration can be found for element “”context:component-
 scan””.

这两段代码都报这个问题。是因为少jar包还是什么原因,求高手分析

解决方案:40分
不能读取xsd,我没碰到过这种问题,看看是不是url拼错了,就是这一段http://www.springframework.org/schema/context/spring
 context-3.2.xsd
实在不行就找个其他spring工程抄一份xsd的声明

CodeBye 版权所有丨如未注明 , 均为原创丨本网站采用BY-NC-SA协议进行授权 , 转载请注明spring配置,求问applicationContext.xml扫描问题
喜欢 (0)
[1034331897@qq.com]
分享 (0)