K.O. ----- 配置文件沒有提示
---------------siwuxie095
K.O. ----- 配置文件沒有提示
1、解決方法一:聯網
只要 PC 聯網,配置文件中就有提示
2、解決方法二:手動導入約束文件
約束文件:hibernate-mapping-3.0.dtd 和 hibernate-configuration-3.0.dtd
二者在 project\hibernate-core\src\main\resources\org\hibernate 文件夾下:
hibernate-release-5.0.12.Final.zip
https://sourceforge.net/projects/hibernate/files/hibernate-orm/5.0.12.Final/hibernate-release-5.0.12.Final.zip/download
下載並解壓後,具體導入過程:
打開 Eclipse,Window->Preferences->XML->XML Catalog,
點擊 Add... 進行添加,其中:
1)Location 即 約束文件的路徑
2)Key type 選擇 URI
3)Key 即 http://www.hibernate.org/dtd/hibernate-mapping-3.0.dtd
和 http://www.hibernate.org/dtd/hibernate-configuration-3.0.dtd
最後,重啟 Eclipse 即可生效
「不光是 Hibernate 的配置文件,其它的配置文件也是類似」
【made by siwuxie095】
K.O. ----- 配置文件沒有提示