[hibernate-dev] Discovering/configuring package-info

Christian Bauer hibernate at christianbauer.name
Mon Mar 18 12:11:54 EDT 2013


On 18.03.2013, at 17:09, Steve Ebersole <steve at hibernate.org> wrote:

> Out of curiosity, where is this documented as being supported?

http://docs.jboss.org/hibernate/entitymanager/3.6/reference/en/html/configuration.html

The class element specifies a fully qualified class name that you will map. By default all properly annotated classes and all hbm.xml files found inside the archive are added to the persistence unit configuration. You can add some external entity through the class element though. As an extension to the specification, you can add a package name in the <class> element (eg <class>org.hibernate.eg</class>). Caution, the package will include the metadata defined at the package level (ie in package-info.java), it will not include all the classes of a given package.




More information about the hibernate-dev mailing list