Object diagrams

In UML, object diagrams provide a snapshot of the instances in a system and the relationships between the instances. By instantiating the model elements in a class diagram, you can explore the behavior of a system at a point in time.

An object diagram is a UML structural diagram that shows the instances of the classifiers in models. Object diagrams use notation that is similar to that used in class diagrams. However, while class diagrams show the actual classifiers and their relationships in a system, object diagrams show specific instances of those classifiers and the links between those instances at a point in time. You can create object diagrams by instantiating the classifiers in class, deployment, component, and use-case diagrams.

The following figure shows a simple class diagram that consists of two classes connected by an association.

The following figure shows the corresponding object diagram that consists of two instance specifications connected by a link relationship.

Object diagrams are helpful in the following situations:

The following topics describe the elements in object diagrams:


Feedback