Practical Application for Software Engineering: UML Sequence Diagram

Instructor: Scott Tuning

Scott has been a faculty member in higher education for over 10 years. He holds an MBA in Management, an MA in counseling, and an M.Div. in Academic Biblical Studies.

UML sequence diagrams, also called event diagrams, are useful to software developers who are experimenting with software behavior. They are especially helpful at predicting behavior in any given run-time scenario.

UML Sequence Diagram Revisited

A UML (Unified Modeling Language) sequence diagram, sometimes known as an event diagram, is a visualization that maps out the flow of messages between classes. They are useful for a variety of technology scenarios, but they are especially effective at modeling run-time scenarios.

This predictive modeling is important to developers because it validates their design and alerts them to any interactions between classes that could otherwise have been overlooked.

If you were developing software for a smart refrigerator, your UML sequence might be similar to the example below.

Step 1: Document the Classes

Classes represent the behavior of various objects whenever they are subjected to a given condition. In this diagram, your object is a smart refrigerator and your classes are the various ways the appliance's features will behave in a specific situation or context. Classes are usually plotted as rectangles with text.

These are some of the classes you might use when drawing an event diagram for the smart appliance.
UML Sequence Classes

Step 2: Document the Interactions and Executions

The interactions between classes represent the informational flow and processing patterns. Message being ''sent'' are usually plotted as solid-line arrows. Return messages are usually plotted with a broken or dashed-line arrow.

Two information exchanges. The first is for updating the screen with internet-sourced data. The second exchange represents messages that will modify the mechanical behavior of the appliance (in this case, a temperature change).
UML Sequence Interactions

Since messages don't travel by themselves, each data exchange will be associated with an execution. An execution is simply the routine or programming that initiates the communication. Actions and executions are usual document using narrow, vertical, rectangular bars.

To unlock this lesson you must be a Member.
Create your account

Register to view this lesson

Are you a student or a teacher?

Unlock Your Education

See for yourself why 30 million people use

Become a member and start learning now.
Become a Member  Back
What teachers are saying about
Try it risk-free for 30 days

Earning College Credit

Did you know… We have over 200 college courses that prepare you to earn credit by exam that is accepted by over 1,500 colleges and universities. You can test out of the first two years of college and save thousands off your degree. Anyone can earn credit-by-exam regardless of age or education level.

To learn more, visit our Earning Credit Page

Transferring credit to the school of your choice

Not sure what college you want to attend yet? has thousands of articles about every imaginable degree, area of study and career path that can help you find the school that's right for you.

Create an account to start this course today
Try it risk-free for 30 days!
Create an account