[ Intro ]
[ Requirements ]
[ Domain Objects ]
[ Use Cases ]
[ State Diagram ]
[ Interaction Diagram ]
[ CRC Cards ]
[ Class Diagram ]
[ Class Desc. Forms ]
[ Operation Desc. Forms ]
[ Code ]
[ Executable ]
Name | ATM |
Base class(es) | |
Purpose | Manage the ATM and component parts |
States | running |
stopped | |
Constructors | ATM(number, location, bank) |
Operations | |
Mutators | startupOperation() |
serviceCustomers(initialCash) | |
Accessors | getPIN() |
getMenuChoice(whatToChoose, numItems, items) | |
getAmountEntry() | |
checkIfCashAvailable(amount) | |
dispenseCash(amount) | |
acceptEnvelope() | |
issueReceipt(cardNumber, serialNumber, description, amount, balance, availableBalance) | |
reEnterPIN() | |
reportTransactionFailure(explanation) | |
ejectCard() | |
retainCard() | |
number() | |
Fields | _number |
_location | |
_bank | |
_state | |
_cardReader | |
_display | |
_keyboard | |
_cashDispenser | |
_envelopeAcceptor | |
_receiptPrinter | |
_operatorPanel |
[ View C++ class declaration code ] [ View Java interface documentation ]
Name | CardReader |
Base class(es) | |
Purpose | Manage the magnetic stripe card reader |
States | card not inserted |
card inserted but unreadable | |
card inserted and readable | |
Constructors | CardReader() |
Operations | |
Mutators | ejectCard() |
retainCard() | |
checkForCardInserted() | |
Accessors | cardNumber() |
Fields | _status |
_cardNumberRead |
[ View C++ class declaration code ] [ View Java interface documentation ]
Name | Display |
Base class(es) | |
Purpose | Manage the video display unit |
States | Each screen that can be displayed constitutes a distinct state |
Constructors | Display() |
Operations | |
Mutators | requestCard() |
requestPIN() | |
displayMenu(whatToChoose, numItems, items) | |
requestAmountEntry() | |
requestDepositEnvelope() | |
reportCardUnreadable() | |
reportTransactionFailure(explanation) | |
requestReEnterPIN() | |
reportCardRetained() | |
echoInput(echo) | |
clearDisplay() | |
Accessors | |
Fields |
[ View C++ class declaration code ] [ View Java interface documentation ]
Name | Keyboard |
Base class(es) | |
Purpose | Manage the keys used for customer input |
States | |
Constructors | Keyboard() |
Operations | |
Mutators | readPIN(echoOn) |
readMenuChoice(numItems) | |
readAmountEntry(echoOn) | |
Accessors | |
Fields |
[ View C++ class declaration code ] [ View Java interface documentation ]
Name | CashDispenser |
Base class(es) | |
Purpose | Manage the cash dispenser |
States | |
Constructors | CashDispenser() |
Operations | |
Mutators | setCash(initialCash) |
dispenseCash(amount) | |
Accessors | currentCash() |
Fields | _currentCash |
[ View C++ class declaration code ] [ View Java interface documentation ]
Name | EnvelopeAcceptor |
Base class(es) | |
Purpose | Manage the slot that accepts a deposit envelope from the customer |
States | |
Constructors | EnvelopeAcceptor() |
Operations | |
Mutators | acceptEnvelope() |
Accessors | |
Fields |
[ View C++ class declaration code ] [ View Java interface documentation ]
Name | ReceiptPrinter |
Base class(es) | |
Purpose | Manage the printer that produces customer receipts |
States | |
Constructors | ReceiptPrinter() |
Operations | |
Mutators |
printReceipt(theATMnumber, theATMlocation, cardNumber, serialNumber,description, amount, balance, availableBalance) |
Accessors | |
Fields |
[ View C++ class declaration code ] [ View Java interface documentation ]
Name | OperatorPanel |
Base class(es) | |
Purpose | Manage the panel that allows the operator to start/stop the machine, and to enter initial cash amount. |
States | Switch in running position |
Switch in stopped position | |
Constructors | OperatorPanel() |
Operations | |
Mutators | switchOn() |
getInitialCash() | |
Accessors | |
Fields |
[ View C++ class declaration code ] [ View Java interface documentation ]
Name | Session |
Base class(es) | |
Purpose | Perform a session use case |
States | running |
aborted due to repeated invalid PINs | |
Constructors | Session(cardNumber, atm, bank) |
Operations | |
Mutators | doSessionUseCase() |
doInvalidPINExtension() | |
doFailedTransactionExtension(reason) | |
Accessors | cardNumber() |
PIN() | |
Fields | _cardNumber |
_atm | |
_bank | |
_state | |
_PIN | |
_currentTransaction |
[ View C++ class declaration code ] [ View Java interface documentation ]
Name | Transaction |
Base class(es) | |
Purpose | Abstract common features of the various types of transaction use cases |
States | |
Constructors | Transaction(session, atm, bank) |
chooseTransaction(session, atm, bank) | |
Operations | |
Mutators | doTransactionUseCase() |
(abstract) getTransactionSpecificsFromCustomer() | |
(abstract) sendToBank() | |
(abstract) finishApprovedTransaction() | |
Accessors | |
Fields | _session |
_atm | |
_bank | |
_serialNumber | |
_newBalance | |
_availableBalance | |
static _lastSerialNumberAssigned |
[ View C++ class declaration code ] [ View Java interface documentation ]
Name | WithdrawlTransaction |
Base class(es) | Transaction |
Purpose | Perform a withdrawl transaction use case |
States | |
Constructors | WithdrawlTransaction(session, atm, bank) |
Operations | |
Mutators | getTransactionSpecificsFromCustomer() |
sendToBank() | |
finishApprovedTransaction() | |
Accessors | |
Fields | _fromAccount |
_amount |
[ View C++ class declaration code ]
(Java interface documentation same as for
class Transaction)
Name | DepositTransaction |
Base class(es) | Transaction |
Purpose | Perform a deposit transaction use case |
States | |
Constructors | DepositTransaction(session, atm, bank) |
Operations | |
Mutators | getTransactionSpecificsFromCustomer() |
sendToBank() | |
finishApprovedTransaction() | |
Accessors | |
Fields | _toAccount |
_amount |
[ View C++ class declaration code ]
(Java interface documentation same as for
class Transaction)
Name | TransferTransaction |
Base class(es) | Transaction |
Purpose | Perform a transfer transaction use case |
States | |
Constructors | TransferTransaction(session, atm, bank) |
Operations | |
Mutators | getTransactionSpecificsFromCustomer() |
sendToBank() | |
finishApprovedTransaction() | |
Accessors | |
Fields | _fromAccount |
_toAccount | |
_amount |
[ View C++ class declaration code ]
(Java interface documentation same as for
class Transaction)
Name | InquiryTransaction |
Base class(es) | Transaction |
Purpose | Perform an inquiry transaction use case |
States | |
Constructors | InquiryTransaction(session, atm, bank) |
Operations | |
Mutators | getTransactionSpecificsFromCustomer() |
sendToBank() | |
finishApprovedTransaction() | |
Accessors | |
Fields | _fromAccount |
[ View C++ class declaration code ]
(Java interface documentation same as for
class Transaction)
Name | Bank |
Base class(es) | |
Purpose | Manage communications with the bank |
States | |
Constructors | Bank() |
Operations | |
Mutators |
initiateWithdrawl(cardNumber, PIN, ATMnumber, serialNumber, from, amount,newBalance, availableBalance) |
finishWithdrawl(ATMnumber, serialNumber, succeeded) | |
initiateDeposit(cardNumber, PIN, ATMnumber, serialNumber, to, amount, newBalance, availableBalance) | |
finishDeposit(ATMnumber, serialNumber, succeeded) | |
doTransfer(cardNumber, PIN, ATMnumber, serialNumber, from, to, amount, newBalance, availableBalance) | |
doInquiry(cardNumber, PIN, ATMnumber, serialNumber, from, newBalance, availableBalance) | |
Accessors | chooseAccountType(purpose, atm) |
accountName(type) | |
rejectionExplanation(code) | |
Fields |
[ View C++ class declaration code ] [ View Java interface documentation ]