-->
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.  [ 1 post ] 
Author Message
 Post subject: How to map a "bridge"?
PostPosted: Sun Mar 14, 2004 11:40 pm 
Regular
Regular

Joined: Wed Dec 03, 2003 9:41 pm
Posts: 87
In my domain object, there is a concept class: Storage_move_bill. There are two attribute exist in this concept class: Move type and Storage. Move type means either move_in or move_out. Source storage means diffierent storage: e.g. source storage, scrap storage, product storage. So there are a number of Storage_move_bill, like source_storage_move_out_bill, scrap_storage_move_in_bill, product_storage_move_in_bill, product_storage_move_out_bill and so on.
I designed a common Storage_move_bill class, two interface: Move_type and Storage. There is two attributes named moveType and storage in Storage_move_bill class. A lot of subclass of interface Move_type and Storage.
In DB, all kinds of Storage_move_bill store in one table, two columns distinguish which storage and which move type.
But I have no idea how to map my class to DB. Is there any suggestion?


Top
 Profile  
 
Display posts from previous:  Sort by  
Forum locked This topic is locked, you cannot edit posts or make further replies.  [ 1 post ] 

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.