Skip to main content

XML.com: Guide to UML Class Diagrams

Popularity Report

Total Popularity Score: 0

Loading...
Loading...
Loading...
Loading...
Loading...
Loading...

Rank

URL Tag Cloud

Bookmark History

Saved by 1 people (0 private), first by anonymouse user on 2007-12-16


Public Sticky notes

Relationships

The relationships between two classes can be of the following three types:

  • Association
  • Aggregation
  • Dependency

An Association is a bi-directional connection between classes (e.g. the "hires/works for" relationship between an "employee" class and a "boss" class). It is represented by a solid line.

An Aggregation is the relationship between the whole and its parts. An aggregation is represented as a line connecting the related classes with a diamond next to the class representing the whole.

A Dependency is a relationship where the client does not have semantic knowledge of the supplier. It can be used, for example to show the relationship between an "encoder" class and a "genericAlgorithm" class that is inserted in runtime to help it encode a stream. A dependency is shown as a dashed line pointing from the client to the supplier.

Finally there is Inheritance. Inheritance is represented by a line ending on a triangle on the parent class.

The following example illustrates the concepts above

Highlighted by mikeem

Highlighted by mikeem

Readers (1)