Sequence Diagrams 2.1 - Michael, Rebekah, Zach.pdf

Add Rentable Item (both types) Use Case Sequence Diagram
:InventoryPane
Clerk
Click Add
Ordinary
Rental Item
:GUI
:OrdinaryRentalItemDetailsCard
:InventoryUseCases
:OrdinaryRentalItem
:StoreDatabase
goToCard(“Or
dRentItem”)
(card shown)
Input description, rental charges, and rental period
[if clerk wants to add the item]
addOrdRentItem(desc
ription,
rentalCharges,
rentalPer)
Click Add
if input is in the wrong
format, an
IllegalArgumentException is
thrown and GUI displays an
error
<< create >>
(description,
rentalCharges,
rentalPer)
addRentableItem(
this)
[if clerk wants to cancel the transaction]
Click Cancel
goBack()
Click Add
Rent-toItem
goToCard(“Ren
tToOwnItem”)
:RentToOwnItemDetailsCard
(card shown)
:RentToOwnItem
Input description, monthlyPayments, and numOfPayments
[if clerk wants to add the item]
addRentToOwnItem(
description,
monthlyPayments,
numOfPayments)
Click Add
if input is in the wrong
format, an
IllegalArgumentException is
thrown and GUI displays an
error
[if clerk wants to cancel the transaction]
Click Cancel
goBack()
<< create >>
(description,
montlyPayments,
numOfPayments)
addRentableItem(this)
Produce Customer Report Use Case Sequence Diagram
:ReportsPane
:StoreDatabase
:Customer
:Rent
:SimpleDate
:Copy
:RentableItem
Clerk Click
Customer
Report
produceCusto
merReport()
produceReport()
[for each customer]
getFullName(),
getAddress(),
getPhoneNumbe
r(), getRentals(),
getRentals().size
isLate()
[for each rent]
isLateBooleanResult
[if isLateBooleanResult true]
getCopy()
copy
getDescription()
getDescrip
tion()
description
A report with the Customer
information and the late
rentals with description and
due dates of stated copies are
printed to System.out for
each customer
description
getDueDate()
dueDate