I'm using AnnotationConfiguration.class in hibernate-annotations.jar from 3.1B4 distribution. There is no addPackage method there. Just trying to follow the manual (
http://www.hibernate.org/hib_docs/annot ... e/#d0e1128):
sessionFactory = new
AnnotationConfiguration().addPackage("test")
.addAnnotatedClass(Flight.class)
.addAnnotatedClass(Sky.class)
.addAnnotatedClass(Person.class)
.addAnnotatedClass(Dog.class)</b>
.buildSessionFactory();
Gives:
cannot find symbol method addPackage(java.lang.String)