Documente Academic
Documente Profesional
Documente Cultură
User
Requirements 2
Modeling
Analysis
Modeling
Design
Modeling
6
Incremental
Software
Construction
Throwaway
Prototyping
Incremental
Software
Integration
8
Customer
11
12
13
10
Incremental
Prototyping
9
15
System
Testing
14
A-1
Dynamic Modeling
Use cases realized in Dynamic Model
Show objects participating in each use case
Determine how objects participate in use case
Use object structuring criteria to determine objects
Stereotype for each object structuring criterion
Shows sequence of object interactions in use case
Depict on
communication diagram or
sequence diagram
State
S
ddependent
d controll objects
bj
Modeled using statecharts
Dynamic Modeling
Approach to determine how objects interact with each
other to support use case
4
Copyright 2011 H. Gomaa
A-2
Dynamic Modeling
Determine how objects interact with each other to support
use case
Start with external event from actor
Determine objects needed to support use case
Determine sequence of internal events following
external event
Depict on communication diagram or sequence diagram
Stateless Dynamic Modeling
p
Dynamic
y
Modelingg
State dependent
Important for real-time design
5
Copyright 2011 H. Gomaa
Communication Diagram
Graphically depicts objects interacting with each other
Show objects as boxes
Show their message interactions as arrows
Number sequence of messages
A1:
Operator
Request
user interaction
: Operator
Interaction
A1.3:
Display Info
: Monitoring Operator
A1.1: Alarm
Request
A1.2: Alarm
service
: Alarm
Service
A-3
Sequence Diagram
Shows sequence of object interactions in use case
Emphasis on messages passed between objects
Objects represented by vertical lines
Messages represented by labeled horizontal arrows
Dynamic Modeling
Determine how objects interact with each other to support
use case
Startt with
w t external
e te a event
eve t from
o actor
acto
Sta
Determine objects needed to support use case
Determine sequence of internal events following
external event
Depict on communication diagram or sequence diagram
Stateless (non state-dependent) Dynamic Modeling
State dependent Dynamic Modeling
dm-8
Copyright 2011 H. Gomaa
A-4
dm-9
Monitoring Operator
A1:
Operator
Request
A1.3:
p y Info
Display
: Monitoring Operator
user interaction
: Operator
Interaction
A1.1: Alarm
Request
A1.2: Alarm
service
: Alarm
Service
dm-10
Copyright 2011 H. Gomaa
A-5
dm-12
Copyright 2011 H. Gomaa
A-6
13
Copyright 2011 H. Gomaa
A-7
15
Copyright 2011 H. Gomaa
Figure 11.2 Sequence Diagram for Validate PIN use case Valid Pin
external I/O
device
: CardReader
external
user
: ATM
Customer
Keypad
Display
I/O
: CardReader
Interface
state
dependent
control
: ATMControl
entity
: ATMCard
user
interaction
: Customer
Interaction
entity
:
ATMTransaction
subsystem
: Banking
Service
sd PIN Validation
16
Copyright 2011 H. Gomaa
A-8
Idle
1.2: Card Inserted /
1.3: Get PIN
Entry /
Display Welcome
Validating PIN
Waiting for
Customer
Choice
17
Copyright 2011 H. Gomaa
Validate PIN
Main and Alternative Scenarios
Valid card and PIN entered
2.6 [Valid]: Valid PIN
Incorrect PIN
2.6A* [Invalid]: Invalid PIN
Iteration of messages: 2.6A.1 through 2.6A.8.
Incorrect PIN entered three times
2.6B [Third Invalid]: Third Invalid PIN
C
Card stolen or expiration
p
date expired.
p
2.6C [Stolen OR expired]: Card stolen, Card expired
Card not recognized:
1.1A [card not recognized] Eject Card
Cancel
2A.2 Eject
dm-18
A-9
19
Copyright 2011 H. Gomaa
Figure 11.6 Sequence Diagram for Validate PIN use case Stolen or Expired Card
external I/O
device
: CardReader
external
user
: ATM
Customer
Keypad
Display
I/O
: CardReader
Interface
entity
: ATMCard
state
dependent
control
: ATMControl
user
interaction
: Customer
Interaction
entity
:
ATMTransaction
subsystem
: Banking
Service
20
Copyright 2011 H. Gomaa
A-10
21
Copyright 2011 H. Gomaa
22
Copyright 2011 H. Gomaa
A-11
dm-23
Copyright 2011 H. Gomaa
dm-24
A-12
Figure 21.16 Communication diagram: ATM Client Withdraw Funds use case
25
Copyright 2011 H. Gomaa
dm-26
Copyright 2011 H. Gomaa
A-13
User
Requirements 2
Modeling
Analysis
Modeling
Design
Modeling
6
Incremental
Software
Construction
Throwaway
Prototyping
Incremental
Software
Integration
8
Customer
11
12
13
10
Incremental
Prototyping
9
15
System
Testing
14
27
A-14