Section 8.3. State Machine Extension


8.3. State Machine Extension

Like many other concepts in UML, state machines may be specialized as needed. A specialized state machine is an extension of a general state machine. You can specialize a state machine by adding regions, states, pseudostates, or transitions. In addition to adding features to state machines you can redefine states, regions, and transitions.

When drawing a specialized state machine, draw the inherited states with dashed or gray-toned lines. You may also place the keyword extended in curly braces after the name of the state machine. Figure 8-16 shows a specialized soda dispensing state machine. The Dispensing Drink state is extended to introduce a new substate, Out of selection. The states Releasing drink and Refunding change retain their other transitions, and a new transition, Time expired, is added to transition to the new substate if the IR sensor isn't triggered (see Figure 8-6 for the original composite state).




UML 2.0 in a Nutshell
UML 2.0 in a Nutshell (In a Nutshell (OReilly))
ISBN: 0596007957
EAN: 2147483647
Year: 2005
Pages: 132

flylib.com © 2008-2017.
If you may any questions please contact us: flylib@qtcs.net