-->
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: Missing Method Collection.getOneToMany() in Hibernate 2.1rc1
PostPosted: Sat Nov 29, 2003 11:18 am 
Newbie

Joined: Thu Nov 13, 2003 1:14 pm
Posts: 18
Location: Leinfelden-Echterdingen, Germany
Hi,

with Hibernate 2.1beta6 I did something like

net.sf.hibernate.mapping.Collection collection = ...;
collection.getOneToMany().getAssociatedClass()

to determine the type of the elements contained in a collection. I just downloaded rc1. It seems that the method getOneToMany does not exist anymore with this new version.

Could anyone please tell me how I can get the same information with the rc1 api?

Thanks,

Peter


Top
 Profile  
 
 Post subject:
PostPosted: Sat Nov 29, 2003 11:31 am 
Hibernate Team
Hibernate Team

Joined: Tue Aug 26, 2003 12:50 pm
Posts: 5130
Location: Melbourne, Australia
use getValue().getType().getReturnedClass()

it is much more elegant and polymorphic now ;)


Top
 Profile  
 
 Post subject:
PostPosted: Sat Nov 29, 2003 12:02 pm 
Newbie

Joined: Thu Nov 13, 2003 1:14 pm
Posts: 18
Location: Leinfelden-Echterdingen, Germany
Thanks Gavin,

your reply delay is unbelievable! Nearly like having you on the phone ;-)


Quote:
use getValue().getType().getReturnedClass()

Btw., in case anyone other reads this thread. It's

Code:
getElement().getType().getReturnedClass()


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.