umlobject-diagram

What is the purpose of an UML Object Diagram?


I'd like to clarity something:

As I understand it, the purpose of object diagram is to show relationships among objects. The sequence in which these objects interact is not relevant. Is this correct?

If possible, could you provide general comments on the diagram below:

a sample UML Object Diagram


Solution

  • Yes, the goal of an object diagram is to show the relationships between a set of objects (i.e. the links/pointers between them).

    The object diagram shows a static snapshot of the system. Objeect diagrams are not useful to show the sequence of events they exchange (not even those that provoke the system to reach the current state represented by the object diagram). You have the interaction diagrams for this. In particular, the collaboration diagram, looks very similar to an object diagram but the "lines" in it represent method calls, not links