Visual Paradigm Logo
     Build Quality Applications Faster, Better and Cheaper
 
Home | Products | Download | Documentation | Support | Resources | Partners | Quick Tour | Shop | Company |  
 
   Visual Paradigm Discussion Forum
  Login   [ Register ] Email: Password: Log me on automatically I lost my password  
Recent Topics
Advanced Search
Source files from Class containment  
Forum Index -> UML Questions
Author Message
Guillaume


Joined: 2007/07/02
Messages: 12

Offline

Hi,

I'm not sure if it's the right forum to ask this open question, please move it to a better place if any:

In UML you can have the definition of a Class contained in another class.
For my point of view, it's happens when an instance of the sub-class cannot exist without an instance of the containing Class.
i.e. a Line of Invoice cannot exists without an Invoice.

So in such case I think the code of those classes can be in the same source file. Because there is no advantage to separate them in two files.
I do that in PHP (and I think also in C++ but it's a long time ago and I'm not sure).
Do you think it's a good idea ?

Thanks for your comments,
Cheers,
Guillaume
 
 
   Forum Index -> UML Questions
Go to:   
Powered by JForum 2.1.4 © 2005 - Rafael Steil