01.01.2015 Views

UML Weekend Crash Course™ - To Parent Directory

UML Weekend Crash Course™ - To Parent Directory

UML Weekend Crash Course™ - To Parent Directory

SHOW MORE
SHOW LESS

Create successful ePaper yourself

Turn your PDF publications into a flip-book with our unique Google optimized e-Paper software.

172<br />

Saturday Afternoon<br />

Bill : Customer<br />

Bill's Order : Order<br />

: Inventory<br />

1<br />

1: Order()<br />

2: return order<br />

3 *[for each product] : additem(product,qty)<br />

4: addProduct(product,qty)<br />

3<br />

5: productAvailable(product,qty)<br />

<br />

4<br />

6: return yes<br />

7: reduceInventory(product,qty)<br />

8: return done<br />

5<br />

2<br />

9: return done<br />

10: cancel()<br />

Figure 16-3 Extended elements of the Sequence diagram notation<br />

Observe these notations in Figure 16-3:<br />

1. Activation: The start of the vertical rectangle, the activation bar<br />

2. Deactivation: The end of the vertical rectangle, the activation bar<br />

3. Timeout event: Typically signified by a full arrowhead with a small clock face<br />

or circle on the line<br />

4. Asynchronous event: Typically signified by a stick arrowhead<br />

5. Object termination symbolized by an X<br />

X<br />

Figure 16-3 also introduces some new types of messages. Reference #3 points to a message<br />

with a circle on the line and the stereotype . This is called a timed event.<br />

Often there is also a condition or a constraint on the message that expresses the timing<br />

parameters for the event, for example, {if we don’t get a response from inventory within<br />

2 seconds we will bypass the item and check later}. The timeout is an example of a <strong>UML</strong><br />

extension. It is not a part of the core <strong>UML</strong> notation, but represents a valid usage.

Hooray! Your file is uploaded and ready to be published.

Saved successfully!

Ooh no, something went wrong!