Please forgive me, this is probably a stupid/obvious question, but I have searched around for the last 2 days and am stuck...
I am rather new to Hibernate and Ant, and I have been trying to get hbm2java to work as an automated Ant process. I found this information here:
http://www.hibernate.org/98.html about setting up hbm2java as an optional ant task. I added this to my hbm2java target in my build.xml:
<taskdef
name="hbm2java"
classname="net.sf.hibernate.tool.hbm2java.CodeGenerator"
classpathref="hbm.classpath"
/>
<hbm2java
output="${javaoutput.dir}"
>
<fileset dir="${mappingoutput.dir}">
<include name="**/*.hbm.xml"/>
</fileset>
</hbm2java>
However, I get this error:
BUILD FAILED
file:C:/java/Middlegen-Hibernate-r2/build.xml:308: No public execute() in class net.sf.hibernate.tool.hbm2java.CodeGenerator
I am pretty sure that is because I need to code up an Ant task for hbm2java. Is this included somewhere in the Hibernate-2.0.3 files or in the tools files, or do I need to write this myself? Also, where would I put that Hbm2javaTask class file?
Thanks so much,
-Kat