-->
These old forums are deprecated now and set to read-only. We are waiting for you on our new forums!
More modern, Discourse-based and with GitHub/Google/Twitter authentication built-in.

All times are UTC - 5 hours [ DST ]



Forum locked This topic is locked, you cannot edit posts or make further replies.  [ 3 posts ] 
Author Message
 Post subject: hbm2java and hibernate3
PostPosted: Tue Mar 06, 2007 5:06 pm 
Beginner
Beginner

Joined: Thu Jan 22, 2004 2:42 pm
Posts: 24
I am trying to find instructions on how I can use hbm2java on a simple set of hbm files I have. But the hibernate3 documentation isn't very forthcoming; I attempted to follow these instructions but I don't think they are relevant: http://www.onjava.com/lpt/a/6382


How can I simply run hbm2java in hibernate3?


Top
 Profile  
 
 Post subject:
PostPosted: Tue Mar 06, 2007 8:21 pm 
Hibernate Team
Hibernate Team

Joined: Tue Aug 26, 2003 7:19 pm
Posts: 2364
Location: Brisbane, Australia
Hibernate tools has its own online manual - have you looked at the tools secion under documentation?

Just in case heres a link.

http://www.hibernate.org/hib_docs/tools/reference/en/html/


Top
 Profile  
 
 Post subject: Re: hbm2java and hibernate3
PostPosted: Wed Mar 07, 2007 4:29 am 
Beginner
Beginner

Joined: Wed Jan 31, 2007 11:39 am
Posts: 24
ravalox wrote:
How can I simply run hbm2java in hibernate3?


Why do you want to use the hbm2java?To create pojos?

Then if you are using build.xml you can use something like the following taskdef:


Code:
<taskdef name="hibernatetool"
classname="org.hibernate.tool.ant.HibernateToolTask"
classpathref="classpath"/>
   
<target name="createPojos" depends="clean" >
<hibernatetool  destdir="${srcDir}">
<configuration>
<fileset dir="${srcDir}">
    <include name="**/*.hbm.xml"/>
</fileset>
</configuration>
<hbm2java jdk5="false"/>
</hibernatetool>
</target>


Top
 Profile  
 
Display posts from previous:  Sort by  
Forum locked This topic is locked, you cannot edit posts or make further replies.  [ 3 posts ] 

All times are UTC - 5 hours [ DST ]


You cannot post new topics in this forum
You cannot reply to topics in this forum
You cannot edit your posts in this forum
You cannot delete your posts in this forum

Search for:
© Copyright 2014, Red Hat Inc. All rights reserved. JBoss and Hibernate are registered trademarks and servicemarks of Red Hat, Inc.