Exercise 2 - Simulation 2
Background
This exercise is built on Exercise 1 - Simulation 1. And the following are the things you should do:
Add a
queuefield in the bank to store the bank queue.Add a
Taskabstract class, with two concrete classes extending fromTaskto represent theDepositTaskandWithdrawal Taskrespectively.Change the operating logic and printing content of some
Events
OOP Design
Class Relationship Diagram
Basically, the UML is quite similar to the Ex1's. The "difficult" point lies in finding the correct logic to trigger each event.
Last updated