UML Diagrams
UML Diagrams
Class diagram
Show the classes of the system, their inter-relationships, and the operations and attributes
of the classes
• Explore domain concepts in the form of a domain model
• Analyze requirements in the form of a conceptual/analysis model
• Depict the detailed design of object-oriented or object-based software
Object-Oriented Design [Year]
Component diagram
shows the dependencies among software components, including the
classifiers that specify them (for example implementation classes) and the
artifacts that implement them; such as source code files, binary code files,
executable files, scripts and tables.
These diagrams show the physical components of a system.
Component diagrams describe the organization of the components in a
system.
Steps to Model:
Identify Artifacts
o Files used in the system.
o Libraries and other artifacts relevant to the application.
o Relationships among the artifacts.
Object-Oriented Design [Year]
Deployment diagram
Object diagram
Useful for exploring real world examples of objects and the relationships
between them. It shows instances instead of classes.
They are useful for explaining small pieces with complicated
relationships, especially recursive relationships.
Object diagrams represent an instance of a class diagram.
The basic concepts are similar for class diagrams and object diagrams.
Object diagrams also represent the static view of a system but this static
view is a snapshot of the system at a particular moment.
Object diagrams can be imagined as the snapshot of a running system at a
particular moment.
Object-Oriented Design [Year]
Package diagram
Simplify complex class diagrams and group classes into packages.
A package is a collection of logically related UML elements.
Packages are depicted as file folders and can be used on any of the UML
diagrams.
Activity diagram
Describes the behavior of the target system from an external point of view.
The purpose of use case diagram is to capture the dynamic aspect of a system.
Use case diagrams are used to gather the requirements of a system including internal and
external influences.
These requirements are mostly design requirements. So when a system is analyzed to
gather its functionalities use cases are prepared and actors are identified.
Use cases. A use case describes a sequence of actions that provide something of
measurable value to an actor and is drawn as a horizontal ellipse.
Object-Oriented Design [Year]
Actors. An actor is a person, organization, or external system that plays a role in one or
more interactions with your system. Actors are drawn as stick figures.
Associations. Associations between actors and use cases are indicated by solid lines. An
association exists whenever an actor is involved with an interaction described by a use
case.
Object-Oriented Design [Year]
Object-Oriented Design [Year]
Interaction Diagrams
The purposes of interaction diagrams are to visualize the interactive behaviour of the
system.
Two types : Sequence Diagram and Collaboration Diagram
Sequence diagram
Collaboration Diagram
It shows the object organization.
In collaboration diagram the method call sequence is indicated by some numbering
technique.
Object-Oriented Design [Year]
Sequence diagrams are used to capture the order of messages flowing from one object to
another.
Collaboration diagrams are used to describe the structural organizations of the objects
taking part in the interaction.