Programmatically loading Entity classes with JPA 2.0?
Posted
by Dennetik
on Stack Overflow
See other posts from Stack Overflow
or by Dennetik
Published on 2010-05-15T02:07:46Z
Indexed on
2010/05/15
2:14 UTC
Read the original article
Hit count: 288
With Hibernate you can load your Entity classes as:
sessionFactory = new AnnotationConfiguration()
.addPackage("test.animals")
.addAnnotatedClass(Flight.class)
.addAnnotatedClass(Sky.class)
.addAnnotatedClass(Person.class)
.addAnnotatedClass(Dog.class);
Is there a way to do the same thing - programmatically loading your Entity classes - in a JPA 2.0 compliant way?
© Stack Overflow or respective owner