Featured

UML Object Diagram

Object Diagram (also known as Instance Diagrams) is a diagram that shows a complete or partial view of the structure of a modeled system at a specific time. This snapshot focuses on some particular set of object instances and attributes, and the links between the instances. A correlated set of object diagrams provides insight into how an arbitrary view of a system is expected to evolve over time.
An object diagram looks like a class diagram, the differences : values are allocated to attributes and method parameters, while a class diagram represents an abstraction on source code, an object diagram is an abstraction of running code.

Objects vs Classes


Interpretation in the real world
Representation in the Model
Object

An object is anything in the real world that can be distinctly identified
An object has an identity, a state, and a behavior
Class

A class is a set of objects with similar structure and behavior. These objects are called instances of the class
A class defines the structure of states and behaviors that are shared by all of its instances
Figure uml.08 an example of a UML Object Diagram



Object Diagrams are more concrete than class diagrams, and are often used to provide examples, or act as test cases for the class diagrams. Only those aspects of a model that are of current interest need be shown on an object diagram. They are useful for exploring “real world” examples of objects and the relationships between them. Although UML class diagrams are very good at describing this very information some people find them too abstract – a UML object diagram can be a good option for explaining complex relationships between classes.
UML Object Diagram

In Object Diagrams, the associations among objects are shown as links. A binary link is shown as a path between two objects. In the case of a reflexive association, it may involve a loop with a single object.
A role name may be shown at each end of the link. An association name may be shown near the path; if present, it is underlined to indicate an instance. Multiplicity is not shown for links because they are instances. Other association adornments (aggregation, composition, navigation) may be shown on the link roles.




www.CodeNirvana.in

Copyright © Computer Science | Blogger Templates | Designed By Code Nirvana