UML: Difference between revisions

From NovaOrdis Knowledge Base
Jump to navigation Jump to search
Line 16: Line 16:
The association between two classes can be further refined by labeling the association, optionally with an arrow that specifies the direction of the relationship:
The association between two classes can be further refined by labeling the association, optionally with an arrow that specifies the direction of the relationship:
:[[File:UML_Association_2.png]]
:[[File:UML_Association_2.png]]
The multiplicity of the relationship can be represented by annotated each end with *, 0, 1. This number is also referred to as cardinality, but cardinality is not the correct term. <font color=darkkhaki>Cardinality refers to the actual number of items in a set, whereas multiplicity specifies how small or how large the set could be.</code>

Revision as of 23:27, 26 July 2022

Internal

Overview

UML stands for Unified Modeling Language. UML is useful to quickly communicate the structure and associations within a set of classes.

In UML most things are optional, we only need to specify as much information in a diagram as make sense fr the current situation.

Association

Association is the most basic way for two classes to be related.

UML Association.png

The association between two classes can be further refined by labeling the association, optionally with an arrow that specifies the direction of the relationship:

UML Association 2.png

The multiplicity of the relationship can be represented by annotated each end with *, 0, 1. This number is also referred to as cardinality, but cardinality is not the correct term. Cardinality refers to the actual number of items in a set, whereas multiplicity specifies how small or how large the set could be.