27.6. Derived Elements

A derived element can be determined from others. Attributes and associations are the most common derived elements. When should derived elements be shown?

Avoid showing derived elements in a diagram, since they add complexity without new information. However, add a derived element when it is prominent in the terminology, and excluding it impairs comprehension.


For example, a Sale total can be derived from SalesLineItem and ProductSpecification information (see Figure 27.12). In the UML, it is shown with a “/” preceding the element name.

Figure 27.12. Derived attribute.


As another example, a SalesLineItem quantity is actually derivable from the number of instances of Items associated with the line item (see Figure 27.13).

Figure 27.13. Derived attribute related to multiplicity.


..................Content has been hidden....................

You can't read the all page of ebook, please click here login for view all page.
Reset
18.188.135.58