hibernate 3.1使用(import org.hibernate.cfg.AnnotationConfiguration;)出错
如上图所示:org.hibernate.cfg.AnnotationConfiguration不能够被识别和添加。使用Annotation的方式进行配置,非XML方式。查找原因网上有说原因未添加hibernate3.jar包,但是在我的Hibernate3.1.3中包含了这个文件。
解决方法:添加hibernate-annotations.jar即可