July 2001
Intermediate to advanced
656 pages
15h 51m
English
The endSale system operation occurs when a cashier presses a button indicating the end of a sale. Here is the contract:
Contract CO3: endSale
|
Our first choice involves handling the responsibility for the system operation message endSale. Based on the Controller GRASP pattern, as for enterItem, we will continue to use Register as a controller.
The contract postconditions state:
Sale.isComplete became true (attribute modification).
As always, Expert should be the first pattern considered ...
Read now
Unlock full access