-->
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.  [ 2 posts ] 
Author Message
 Post subject: Problems compiling hbm2dao generated code
PostPosted: Sat Mar 17, 2007 2:41 pm 
Newbie

Joined: Sat Mar 17, 2007 2:17 pm
Posts: 6
Hibernate version: 3.2.2

JDK: 1.4

Hi! I'm happy to leave my first post on hibernate forum!

The problem: i was able to generate and compile pojos files with hbm2java ant target but trying to compile dao interfaces (created with hbm2dao) i got a bunch of these:

Code:
/home/ceztko/development/thgroup/visionehrcv/src/com/thgroup/visionehrcv/model/StatoValutazioneHome.java:99: cannot resolve symbol
symbol  : method get (java.lang.String,int)
location: interface org.hibernate.classic.Session
            StatoValutazione instance = (StatoValutazione) sessionFactory.getCurrentSession().get("com.thgroup.visionehrcv.model.StatoValutazione", id);
                                                                                                                                                  ^


The same error is on all dao classes, all at line 99. My classpath looks OK (surely it see hibernate3.jar, most recent stable version. Dunno if other *.jars are needed, but no NoClassDefFoundError here :-(

Looked hibernate sources and get method with parms String and int is there, in the org.hibernate.Session superclass! So seems no problem there too...

Thanks for your attention!

Francesco, ceztko


Top
 Profile  
 
 Post subject: Re: Problems compiling hbm2dao generated code
PostPosted: Sun Mar 18, 2007 5:23 am 
Newbie

Joined: Sat Mar 17, 2007 2:17 pm
Posts: 6
I give you a link to a pojo .java file that compile (no dependency with other classes) ant its related dao interface (that doesn't).

http://www.webalice.it/ceztko/Provincia.java
http://www.webalice.it/ceztko/ProvinciaHome.java

Both the files are freshly generated using <hbm2java> and <hbm2dao> ant target of HibernateTools 3.2.0b9 using this mapping file: http://www.webalice.it/ceztko/config.hbm.xml

Thanks for your help.

P.S.: Do you know that phpBB URL tags doesn't work with labels here?


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