XDoclet and Hibernate annotations are reverse mapping tools.
They map java classes to HBM files. That has a little practical usage for the heterogeneous projects.
Java->HBM mapping makes sense for the projects that are completely driven by Java code. What is not the case in the big distributed projects where single DB might be used by applications written using different languages. In this case DB->HBM->Java DTO mapping is required to easily update DTO objects after DB was changed. Let take an example.
Imagine that DB has 400 tables. Many of these tables were changed due to new requirements. Now, it is required to regenerate DTO in order to take latest changes made by DB admin and also replace class that is used as PK generator. My generator allows you to do this in 2-3 minutes... Probably there are other tools that are doing the same job but it looks for me that Hibernate Annotations and xDoclet are not in this list.
Middlgen can do dirrect DB->HBM mapping but, as I didnt said, using velocity templates. Unfortunatly at the time I was using it, Middlegen generator was very unflexable in its configuration: Relationship mapping could not be switched off for example, primary key generator class could not be configured for individual tables and some other restrictions were implied.
Eclispse plugins There is a beta-version of some "eclipse-only-working" project that supports reverse engeenering approach. It does about the same job as my generator does and it also allows to map relationship that I currently do not support.
[ May 04, 2006: Message edited by: Stas Sakalou ]
[ May 04, 2006: Message edited by: Stas Sakalou ]
[ May 04, 2006: Message edited by: Stas Sakalou ]
[ May 04, 2006: Message edited by: Stas Sakalou ]
[ May 04, 2006: Message edited by: Stas Sakalou ]
[ May 04, 2006: Message edited by: Stas Sakalou ]
[ May 04, 2006: Message edited by: Stas Sakalou ]