|
UML Sequence
Diagram Tutorial
UML sequence diagrams are used to document the interactions between the
components of a system. Time is represented in the vertical direction
showing the sequence of interactions of the header elements, which are
displayed horizontally at the top of the diagram. Although UML sequence
diagrams are used to describe object-oriented software systems, they are
also extremely useful as system engineering tools to design system
architectures, in business process engineering as process flow diagrams,
as message sequence charts and call flows for telecom/wireless system
design, and for protocol stack design and analysis.
UML sequence
diagrams are used to represent or model the flow of messages, events
and actions between the objects or components of a system. They are
used primarily to design, document and validate the architecture, interfaces
and logic of the system by describing the sequence of actions that need
to be performed to complete a task or scenario. UML sequence diagrams
are useful design tools because they provide a dynamic view of the system
behavior which can be difficult to extract from static diagrams or specifications.
Sequence Diagram Drawing Elements
This tutorial describes the basic drawing elements used in sequence
diagrams and when they are used. These are the diagram elements that are
supported by the
Sequence Diagram Editor tool, some are not part of the UML
specification and may not be supported by other UML tools.
Sequence Diagram Header Elements
The header portion of the sequence diagram represents the components or
objects of the system being modeled and are laid out horizontally at the
top of the diagram.
See an example sequence diagram here.
Actor |
Represents an external person or entity that interacts with the system
|
 |
Object |
Represents an object in the system or one of its components
|
 |
Unit |
Represents a subsystem, component, unit, or other
logical entity in the system (may or may not be implemented by objects) |
 |
Separator |
Represents an interface or boundary between subsystems,
components or units (e.g., air interface,
Internet, network) |
 |
Group |
Groups related header elements into subsystems or components |
 |
Sequence Diagram Body Elements
Action |
Represents an action taken by an
actor, object or unit |
 |
Asynchronous Message |
An asynchronous message between header elements |
 |
Block |
A block representing a loop or conditional for a particular header element |
 |
Call Message |
A call (procedure) message between header elements |
|
Create
Message |
A "create" message that creates a header element (represented by lifeline going from dashed to solid pattern) |
|
Destroy Element |
Represents the destruction of a header element |
 |
Destroy Message |
Represents the destruction of a header element as a result of a call from another element |
 |
Diagram Link |
Represents a
portion of a diagram being treated as a functional block. Similar to a procedure or function call that abstracts functionality or details not shown at this level. Can optionally be linked to another diagram for elaboration. |
 |
Else Block |
Represents an "else" block portion of a diagram block |
|
Flow Note |
Documentation note that is automatically formatted to flow after previous elements |
 |
Free Note |
Documentation note that is free-flowing and can be placed anywhere in the diagram (can also be anchored relative to a flow element) |
 |
Message |
A simple message between header elements |
 |
Page Break |
A page break in the diagram
|
 |
Return Message |
A return message between header elements |
 |
Scenario Start |
Start of a scenario (set of alternatives) |
 |
Scenario Case |
Start of an alternative or case in a scenario |
 |
Scenario End |
End of a scenario |
|
State |
A state change for a header element |
 |
Steady State |
A steady state in the system |
 |
Timer Start |
Start of a timer for a particular header element |
 |
Timer Stop |
Stop of a timer for a particular header element |
 |
Timer Expiration |
Expiration of a timer for a particular header element |
 |
Download Sequence
Diagram Editor for a Risk Free 14-day Trial |