-->
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: XDoclet to Product HBM files has no output
PostPosted: Wed Dec 29, 2004 2:50 am 
Newbie

Joined: Wed Dec 29, 2004 2:37 am
Posts: 11
I have setup a simple ant task to create the hibernate mappings using xdoclet. after days of looking around, i have gotten the results posted below, but in the end it produces no output. Anyone know what I have messed up or how I can move forward to finding out what I;ve done ?

Thanks,


My build.xml is in ROOT, and I am trying to create hbm files for the .java in WEB-INF classes.

using hibernate 2.1, xdoclet 1-2.2, my hibernate class is defined like
Code:
/*
* @hibernate.class table="products"
*/
public class Product {

    /**
     * @hibernate.id column="productid" generator-class="native"
     */
    public int getProduct_id() {

etc


my build.xml looks like

Code:
            <taskdef name="hibernatedoclet"  classname="xdoclet.modules.hibernate.HibernateDocletTask">
                <classpath>
                  <fileset dir="${xdoclet.lib.home}">
                      <include name="*.jar"/>
                  </fileset>
                </classpath>
            </taskdef>
            <!-- Execute the hibernatedoclet task -->
            <hibernatedoclet
                  destdir="${dist}"
                  excludedtags="@version,@author,@todo"
                  force="true"
                  verbose="true"
                  mergedir="${dist}">
                  <fileset dir="" >
            <include name="**/*.java" />
      </fileset>
      <hibernate version="2.0" />
            </hibernatedoclet>               



and my results are:

Code:
prepare:
     [echo] Creating required directories...
    [mkdir] Created dir: C:\development\jshop-dist

hibernate:
[hibernatedoclet] (XDocletMain.start                   47  ) Running <hibernate/
>

BUILD SUCCESSFUL
Total time: 2 seconds


but no files are ever generated -- and it doesnt mention the product.java file that i have defined.. any thoughts?


Top
 Profile  
 
 Post subject:
PostPosted: Wed Dec 29, 2004 12:11 pm 
Senior
Senior

Joined: Wed Aug 27, 2003 4:08 am
Posts: 178
Location: Wiesbaden, Germany
your source fileset is somehow suboptimal... dir="${basedir}/whereveryoursourcesare" would be better...

_________________
Got new hibernate xdoclet plugin? http://www.sourceforge.net/projects/xdoclet-plugins/
... Momentan auf der Suche nach neuen Projekt ode Festanstellung....


Top
 Profile  
 
 Post subject: Tried -- no success
PostPosted: Wed Dec 29, 2004 9:15 pm 
Newbie

Joined: Wed Dec 29, 2004 2:37 am
Posts: 11
I added the basedir to have better code -- unfortunately same results. whats odd is that the examples never showed the result as hacing the Xdoclet start or the number 47. Are there any ways i can get the xdoclet to show more information, a log or something perhaps?

thanks for your patience


Top
 Profile  
 
 Post subject:
PostPosted: Wed Dec 29, 2004 9:26 pm 
Contributor
Contributor

Joined: Thu Nov 06, 2003 9:49 pm
Posts: 104
Location: New York, NY
If you place a log4j.properties file in the classpath for hibernatedoclet you can have detailed control over XDoclet's logging.


Top
 Profile  
 
 Post subject:
PostPosted: Wed Dec 29, 2004 9:57 pm 
Newbie

Joined: Wed Dec 29, 2004 2:37 am
Posts: 11
thanks for the tip.. oddly enough, i moved the hibernate.class to after the author tag, and it works

thanks


Top
 Profile  
 
 Post subject:
PostPosted: Thu Dec 30, 2004 6:18 am 
Senior
Senior

Joined: Wed Aug 27, 2003 4:08 am
Posts: 178
Location: Wiesbaden, Germany
just discovered...
you class comment was not javadoc comment. those start with /** :)

_________________
Got new hibernate xdoclet plugin? http://www.sourceforge.net/projects/xdoclet-plugins/
... Momentan auf der Suche nach neuen Projekt ode Festanstellung....


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.