Professional Documents
Culture Documents
Lecture 8
In this lecture
1
Inputs and outputs of systems analysis
Systems
Analysis & Design
Sequence State
diagrams diagrams
Collaboration Class
diagrams diagrams
Dynamic
Models:
Collaboration diagrams
Sequence Diagrams
Use Object
Case
Model
Model
2
Dynamic Modelling: Sequence Diagrams
Examples
How entering a new sales order into the system will work
How changing a customer's address will be handled
Sequence Diagrams:
How do the they look like?
Objects
O1 O2 O3 O4 O5 indicates
that the
E1 event
E2 effects the
Events object
E3
E4
3
Sequence diagrams & Software Life
Cycle
Sequence diagrams are used in both the
analysis and the design phases:
Sequence Diagrams
:CheckOutController :StudentDB
getStudentINFO(StudentID)
4
Return Values
:CheckOutController :StudentDB :Student
getstudentINFO(studentID)
balance := getstudentBal(studentID)
Message Conditions
:CheckOutController :StudentDB :Student :PayOverDueFineController
getStudentINFO(studentID)
balance := getStudent(studentID)
[balance>0]payFine()
5
Deletion
:CheckOutController :StudentDB :Student :PayOverDueFineController
getStudentINFO(studentID)
balance := getstudentBal(studentID)
[balance>0]payFine()
Deletion
6
Other notations
Multiplicity
Some messages may be sent multiple times
Ex: a patron may check multiple assets
simultaneously.
* before a message indicates that a message may
be sent several times.
Example
7
Example: Invoice use case
.
.
.
8
Print Invoice - class diagram
9
Print Invoice - class diagram
And so we
move on to the
next step of the
scenario
And now we
have a third
object!
10
Add another object to the class
diagram
And we continue
: Print Invoice : Customer : Sales Items : Invoice
Record
11
Add another object to the class diagram
Sales Items
Invoice
12
Put the methods for each object
: Print Invoice : Customer : Sales Items : Invoice
Record
GetName( )
PrintCustName( )
GetAddress( )
PrintCustAddress( )
GetUnbilledItems( )
PrintLines( )
PrintTotal( )
PrintTermsConditions( )
Customer Record
Print Invoice
GetName()
Print()
GetAddress()
Invoice
Sales Items
PrintCustName()
GetItems() PrintCustAddress()
GetUnbilledItems() PrintLines()
PrintTotal()
PrintTermsConditions()
13
Summary
Complicated sequence diagrams (SD) are hard for
users to discuss and they will be used by the
designers in the subsequent design phase.
14