views:

179

answers:

2

How do I generate hibernate domain classes from tables with annotations at field level? I used Hibernate Tools project and generated domain classes from the tables in the database. The generated classes have annotations on the getter methods rather than at the field level. Kindly advice a way to generate domain classes that have the fields annotated. Is there any refactoring facility available in eclipse/IDEA etc.. to move the annotations from method level to field level?

Appreciate your help and time.

A: 

Could you please post if you found out a solution?

gudl
A: 

currently it is necessary to use custom templates. here is more references and examples hot to implement this: https://forum.hibernate.org/viewtopic.php?f=6&t=1003858&p=2429868#p2429868

vitali_y