-->
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.  [ 6 posts ] 
Author Message
 Post subject: State of hbm2java
PostPosted: Tue Jan 31, 2006 9:23 am 
Newbie

Joined: Tue Jan 31, 2006 9:17 am
Posts: 4
Ok, so after spending days sorting through the docs for the hibernate tools there seems to be some sort of transition going on. A lot of the examples were written for hibernate2 and apparently a different strategy is going on in hibernate3.

Could someone clearly describe what is going on? I am after this functionality: from an ant task, generate pojo's from HBM files using the split pattern (generated super class and concrete subclass, empty initially) using a custom template (velocity...)

Can this be done with hibernate3 tools? If so, would someone be kind enough to point me in the right direction for a working example? The docs on the hibernate.org site for tools seem to be gone too...

Thank you in advance, sorry if this has been answered -- there is just so little information that I can find and most of it contradicts each other...

-s


Top
 Profile  
 
 Post subject:
PostPosted: Tue Jan 31, 2006 9:26 am 
Hibernate Team
Hibernate Team

Joined: Tue Aug 26, 2003 6:10 am
Posts: 8615
Location: Neuchatel, Switzerland (Danish)
http://tools.hibernate.org

_________________
Max
Don't forget to rate


Top
 Profile  
 
 Post subject:
PostPosted: Tue Jan 31, 2006 1:16 pm 
Newbie

Joined: Tue Jan 31, 2006 9:17 am
Posts: 4
Sigh.

Even if this link worked, which it doesn't right now, there is no working example of a split java generation operation from ant with custom templates.

http://www.hibernate.org/hib_docs/tools/ant/index.html

404 error...

Is ANYBODY doing this?


Top
 Profile  
 
 Post subject:
PostPosted: Tue Jan 31, 2006 2:02 pm 
Hibernate Team
Hibernate Team

Joined: Tue Aug 26, 2003 6:10 am
Posts: 8615
Location: Neuchatel, Switzerland (Danish)
why are you referring to old links that is nowhere near tools.hibernate.org ?

http://www.hibernate.org/hib_docs/tools ... l/ant.html

that one is available from tools.hibernate.org

sigh!

_________________
Max
Don't forget to rate


Top
 Profile  
 
 Post subject:
PostPosted: Thu Feb 02, 2006 9:38 am 
Newbie

Joined: Tue Jan 31, 2006 9:17 am
Posts: 4
Ooops...my bad. The bookmark came from an answer you gave to someone else earlier -- sorry about that. :)

I've read those docs now and I have a custom velocity template working by placing a directory named "pojo" with a pojo.vm in it in the classpath before the tools jar and using the hbm2java task.

However, I really don't see a way to do the generation gap pattern _Entity.java with the properties and creation of an Entity.java that derives from _Entity.java if it doesn't exist for concrete code.

I'm willing to believe that I'm being dense... a pointer would be appreciated in that case. Sorry about the "sigh" up above, I was feeling pretty frustrated that day, I appreciate the work of the tools team!

Thanks,


Top
 Profile  
 
 Post subject:
PostPosted: Thu Feb 02, 2006 11:52 am 
Hibernate Team
Hibernate Team

Joined: Tue Aug 26, 2003 6:10 am
Posts: 8615
Location: Neuchatel, Switzerland (Danish)
<class name="Entity">
<meta attribute="generated-class">_Entity</meta>
....
</class>

we will hopefully get around adding the feature where all classes does this automatically (which some people seem to prefer for some weird reason ;)

_________________
Max
Don't forget to rate


Top
 Profile  
 
Display posts from previous:  Sort by  
Forum locked This topic is locked, you cannot edit posts or make further replies.  [ 6 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.