The Relationships that exist between Classes

In a class diagram, obviously you can’t have classes just floating around; you need to see the relationship between them. Peruse the content below to see the types of relationships that exist between classes, along with their notation, and also what they actually mean.


An association relation is established, when two classes are connected to each other in any way. For example: A “bank registers account” association can be shown as follows.


An example of this kind of association is many accounts being registered by the bank. Hence, the relationship shows a star sign near the student class (one to many and many to many etc.

Directed Association

By default, an association that exists between classes is bi-directional. Ideally, you may illustrate the flow of the association by utilizing a directed association. The arrowhead indicates the container-contained relationship.

Reflexive Association

An example here is when a class has many different types of responsibilities. For example, an employee of a company can be an executive, assistant manager, or a CEO. There is no symbol that can be used here, however, the relation will point back at the same class.


When a class is formed as a collection of other classes, it is called an aggregation relationship between these classes. It is also called a "has a" relationship.


Composition is a variation of the aggregation relationship. Composition illustrates that a strong life cycle is present between the classes

Generalization and Inheritance

Known as an "is a" relationship since the child class is a type of the parent class. Generalization is the ideal type of relationship that is used to showcase reusable elements in the class diagram. Literally, the child classes "inherit" the common functionality defined in the parent class.


In a realization relationship, one entity (normally an interface) defines a set of functionalities as a contract and the other entity (normally a class) “realizes” the contract by implementing the functionality defined in the contract.

Pre-set Connector Types

There you have it, 8 relationships that exist between classes. Thanks to the varied specialist features (see screen shot below) present on the app, UML design is an efficient and east endeavor.

Image from -

Learn How Creately Diagrams works

Learn How Creately Diagrams works