hibernate 中配置问题 请大神指点一二
这是我的Student.hbm.xml
<?xml version="1.0" encoding='UTF-8'?>
<!DOCTYPE hibernate-mapping PUBLIC
"-//Hibernate/Hibernate Configuration DTD 3.0//EN"
"http://hibernate.sourceforge.net/hibernate-configuration-3.0.dtd">
<hibernate-mapping package="com.bjsxt.hibernate.model">
<class name="Student" table="Student">
<id name="id" column="id" type="integer"></id>
<property name="name"></property>
<property name="age"></property>
</class>
</hibernate-mapping>
报错Exception in thread "main" org.hibernate.InvalidMappingException: Could not parse mapping document from resource com/bjsxt/hibernate/model/Student.hbm.xml
Caused by: org.hibernate.InvalidMappingException: Could not parse mapping document from invalid mapping
Caused by: org.xml.sax.SAXParseException: Element type "hibernate-mapping" must be declared.