What are the differences between 'uses' and 'has a' relationships?

John Mitchell

A uses relationship denotes an Association -- see section 2.5.2.2 of the UML v1.3 specification for more information.

A has a relationship denotes an Attribute -- see section 2.5.2.5 of the UML v1.3 specification for more information.

Strictly speaking, they are very similar. In modeling a system, you can often use either one. A simple guideline of when to use one versus the other is whether or not the facet that you're modeling is something "intrinsic" to the nature of that specific object. I.e., the Name is an intrinsic part of an Employee and so the Name makes sense as an attribute of the Employee. On the other hand, a Customer is merely associated with a particular Order since the Customer is not intrinsic to the nature of the Order itself.
0 Comments  (click to add your comment)
Comment and Contribute

 

 

 

 

 


(Maximum characters: 1200). You have 1200 characters left.

 

 

About | Sitemap | Contact