1

I am using ant script for Hibernate Reverse Engineering to generate annotated POJO classes from database tables. In this process, I want to write all details like name of each table and generated class etc. on console. Can you help me with this?

<target name="gen_hibernate" description="Generate Hibernate POJO classes with prefix 'Gen'">                                        
               <hibernatetool >                        
                       <classpath path="${build.dir}/classes"/>
                       <jdbcconfiguration                                
                               configurationfile="${appdir}/generate/hibernate/hibernate.cfg.xml"
                               revengfile="${appdir}/generate/hibernate/hibernate.reveng.xml"
                               packagename="com.pojo.generated"                                                                        
                               detectmanytomany="true"        
                               detectoptimisticlock="true"                                
                               />
</hibernatetool>
</target>
1
  • Which ant task you are using ? Commented Dec 7, 2011 at 14:46

1 Answer 1

3

You should try MinuteProject , it has a very nice JPA2 reverse engineering tool and also a a spring + hibernate layer if you want.

Sign up to request clarification or add additional context in comments.

2 Comments

I want to generate only by using hibernate jars.
There is a version of JPA 2 reverse engineering ..which generate the entities for you ! Pure JPA2 ..independent of the implementation Eclipse Link or Hibernate...

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service and acknowledge you have read our privacy policy.

Start asking to get answers

Find the answer to your question by asking.

Ask question

Explore related questions

See similar questions with these tags.