解决hibernate:referenced file contains errors http hibernate.sourceforge.net hibernate-mapping-3.0.dtd
2013-08-22 22:17
726 查看
今天电脑突然蓝屏,重启后进入eclipse,发现项目下的hibernate_cfg.xml莫名其妙的报错,在网上找了好久最终尝试后得到了答案,报错的内容是:referenced file contains errors http hibernate.sourceforge.net hibernate-mapping-3.0.dtd,有的人建议修改里面的约束,但是我这是从svn挡下来的项目,不能因为个人提交这种更新,最后的处理方式是:打开Eclipse-->Window-->Preferences-->Web
and XML-->XML Catalog 在右边点击Add XML Catalog Entry ,location就是你的hibernate-configuration-3.0.dtd和hibernate-mapping-3.0.dtd两个dtd在本地的位置,这两个文件你可以从hibernate的源码包里面找到,Key Type选择URI,这是两个dtd,所以你需要add两个,KEY就是与其对应的http://hibernate.sourceforge.net/hibernate-configuration-3.0.dtd
、http://hibernate.sourceforge.net/hibernate-mapping-3.0.dtd ,这都做好了,刷新项目,你会发现错误没有了。
and XML-->XML Catalog 在右边点击Add XML Catalog Entry ,location就是你的hibernate-configuration-3.0.dtd和hibernate-mapping-3.0.dtd两个dtd在本地的位置,这两个文件你可以从hibernate的源码包里面找到,Key Type选择URI,这是两个dtd,所以你需要add两个,KEY就是与其对应的http://hibernate.sourceforge.net/hibernate-configuration-3.0.dtd
、http://hibernate.sourceforge.net/hibernate-mapping-3.0.dtd ,这都做好了,刷新项目,你会发现错误没有了。
相关文章推荐
- 解决hibernate:referenced file contains errors http hibernate.sourceforge.net hibernate-mapping-3.0.dt
- Spring 配置异常解决办法之Referenced file contains errors (http://www.sp
- Referenced file contains errors (http://www.opensymphony.com/xwork/xwork-validator-1.0.2.dtd)的解决
- Referenced file contains errors 解决方法 (转载地址:http://blog.sina.com.cn/s/blog_6a6b141001011xhn.html)
- 关于:Referenced file contains errors (http://www.springframework.org/schema/beans/spring-beans-4.2错的解决
- Referenced file contains errors (http://struts.apache.org/dtds/struts-2.0.dtd). For more information
- Referenced file contains errors 解决方法
- Referenced file contains errors(http://www.springframework.org/schema/data/mongo/spring-mongo-1.0.x)
- Referenced file contains errors (http://www.springframework.org/schema/beans/spring-beans-3.1.xsd)
- Referenced file contains errors (http://www.springframework.org/schema/mvc/spring-mvc-3.2.xsd)
- Spring 配置异常解决办法之Referenced file contains errors
- Referenced file contains errors 解决方法
- Referenced file contains errors (http://www.springframework.org/schema/beans/spring-beans-2.5.xsd).
- Referenced file contains errors (http://www.springframework.org/schema/aop/spring-aop-3.0.xsd). For more information, right click on the message in th
- Referenced file contains errors http://www.springframework.org/schema/context/spring-context-3.1.xsd
- Referenced file contains errors 解决方法
- 搭建hibernate.cfg.xml时配合错误分享Referenced file contains errors
- servlet.xml 出现 Referenced file contains errors(http://.......)
- Referenced file contains errors (http://www.springframework.org/schema/beans/spring-beans-3.1.xsd).
- Referenced file contains errors (http://www.springframework.org/schema/beans/spring-beans-4.2.xsd).