I'm trying to model something like a category that can have subcategories.



I create a class called Category that has a relationship with itself like:





 ------------

&nbsp;| Category |<>---|1 

&nbsp;------------&nbsp; &nbsp; &nbsp;|ParentCategory

&nbsp; &nbsp; &nbsp; &nbsp;^----------|

&nbsp; &nbsp; &nbsp; &nbsp; &nbsp;0..1 

&nbsp; &nbsp; &nbsp; &nbsp; &nbsp;+SubCategory





The problem is that the DAO generated has a copy method: create(Category 
category) and then also has a create(Category parentCategory) method and 
several more of the like.



I think a way to fix it would be to create a SubCategory class that has a 
circular relationship with Category, but I really don't want to do this.



Any suggestions?



Thad Smith
_________________________________________________________
Reply to the post : http://galaxy.andromda.org/forum/viewtopic.php?p=1112#1112
Posting to http://forum.andromda.org/ is preferred over posting to the mailing 
list!


-------------------------------------------------------
This SF.Net email is sponsored by: NEC IT Guy Games.  How far can you shotput
a projector? How fast can you ride your desk chair down the office luge track?
If you want to score the big prize, get to know the little guy.  
Play to win an NEC 61" plasma display: http://www.necitguy.com/?r=20
_______________________________________________
Andromda-user mailing list
Andromda-user@lists.sourceforge.net
https://lists.sourceforge.net/lists/listinfo/andromda-user

Reply via email to