-->
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: Custom Collection Classes
PostPosted: Mon Nov 10, 2008 3:11 pm 
Newbie

Joined: Mon Nov 10, 2008 3:05 pm
Posts: 1
Hi,
I am looking to accomplish the following

Entity A is linked with a one to many with Entity B

However, I do not want to define a OneToMany Collection of B in Entity A.
Rather, I want to create a OneToOne on Entity A to a custom collection class (CustomA)
CustomA would have a oneToMany of Entity B.

I have tried extending a HashSet to CustomA but that isn't working out for me.

Is there an accepted way of approaching this? Could not find a relevant topic in the forums.

Any help would be greatly appreciated!!

Chris


Top
 Profile  
 
 Post subject:
PostPosted: Mon Nov 10, 2008 3:34 pm 
Expert
Expert

Joined: Fri Jul 13, 2007 8:18 am
Posts: 370
Location: london
Sounds like you should implement CustomA as a "component" class.


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:
cron
© Copyright 2014, Red Hat Inc. All rights reserved. JBoss and Hibernate are registered trademarks and servicemarks of Red Hat, Inc.