Home
Username:
Password:
UML Tutorials

State Diagrams / Protocol State Machines




Visitors to VTC.com will be able to view all introductory videos for each training course.
Free Trial Members will gain access to first three chapters for each training course.
Full Access Members have full access to VTC.com’s entire library of video tutorials.


Learn More

Subtitles of the Movie

As you've seen behavior state machines show the behavior of some element such as an object or a class under specific conditions. You can also model protocol state machines. Rather then modeling an elements behavior a protocol state machine shows a sequence of states and transitions. So you see a sequence of events and the states caused by those events but not the elements actual behavior. This means the protocol state machines don't show the elements activities along transitions or inside the state classifier boxes. So you won't find entry due or exit activities in a protocol state machine. Also along the transitions rather then showing a transition signature that includes trigger, guard and activity as you saw in the behavior state machines, protocol transitions may be labeled as you see here. A precondition in square brackets, event, forward slash and then post condition in square brackets. And it's up to you whether you want to include the preconditions and post conditions. Also when your drawing a protocol state machine enclose your diagram inside a box and in the upper left corner put the name and then protocol inside curly brackets and this will make clear that the state machine that your showing is a protocol state machine. Let's take a quick look at an example, this is a protocol state machine, highly over simplified for a communication protocol. You can see the series of states closed listening, synchronize, receive, established and the transitions between those states. Notice that in this example we only get the name of each state, we don't get any kind of internal activities, no entry due or exit activities and the transitions also are very simply labeled. So what this represents is a sequence of states and the transitions between those states, so it gives us an idea of an ordered sequence of state changes and the transitions between those states. Notice that protocol state machines are not meant to be implemented but simply to show a sequence of transitions and states. So protocol state machines are used to model interfaces and that's what you want to use them for.

Tutorial Information

Course: UML
Author: Nancy Conner
SKU: 33815
ISBN: 1-934743-23-2
Release Date: 2007-10-26
Duration: 7 hrs / 95 lessons
Captions: For Online University members only
Compatibility: Vista/XP/2000, OS X, Linux
QuickTime 7, Flash 8

VTC Sign up & Benefits

  • Unlimited Access
  • 98,729 Video Tutorials (23,265 free)
  • Video Available as Flash or QuickTime
  • Over 1026 Courses
  • $30 for One Month Access
  • Multi-User Discounts Available