문제

i know that hibernate tools can create hibernate entities but the hibernate mapping will be in XML file, but i was wondering if there's a tool to create hibernate entities and the mapping will be with annotations not in XML.

도움이 되었습니까?

해결책

Write your java code and use Source > Generate Hibernate/Jpa annotations and hibernate tools will do an attempt to add necessary annotations based on that

다른 팁

Hibernate tools can also generate the annotated entities by reverse engineering of your database. You have to choose Generate EJB3 annotations and Domain code(.java) . Refer to the 4.5. Reverse Engineering and Code Generation more info. enter image description here

라이센스 : CC-BY-SA ~와 함께 속성
제휴하지 않습니다 StackOverflow
scroll top