1. Trang chủ
  2. » Mẫu Slide

ATM Case Study

36 578 0

Đang tải... (xem toàn văn)

Tài liệu hạn chế xem trước, để xem đầy đủ mời bạn chọn Tải xuống

THÔNG TIN TÀI LIỆU

Thông tin cơ bản

Định dạng
Số trang 36
Dung lượng 211 KB

Nội dung

ATM Case Study A Discussion Case Study A Bank wishes to introduce ATM service to provide limited facilities to her customers Customers may get ATM cards on request Users may view their balance or transfer or withdraw money using these cards Cards may be used to access many accounts and an account may be accessed using different cards A card may be blocked temporarily or permanently (e.g If it is lost) by the Bank A PIN is associated with each card to verify the authority of the user There is an OD limit associated with each cheque account Theoretically, any amount may be withdrawn from a cheque account at any time (provided it is less than the balance+Odlimit) There is no OD facility for a savings account Case Study (cty) The personal information of the customers and their account details are already maintained by the Bank’s main system A subsystem is required to handle the ATM’s functionality Two hardware systems Card reader and Money dispenser will communicate with this subsystem The card reader reads the Card’s ID and passes it to the system It is also able to eject the card when an eject signal is received from the system Similarly the money dispenser is able to dispense the required amount of money Case Study-3 The Limited ATM system is required to provide at least the following operations • Enter a new card / new account detail • Block /Reactivate/Cancel a card • View the balance of the account • Withdraw money from the account • Transfer money from one account to another • Change the PIN of a card The validity of the card and the authority of the User will be checked for each transaction session A Business Activity Diagram Client Clerk Manager :Card [Recorded] Apply for Card Record Detail Approve :Card [Finalised] Finalise Card :Card [Approved] Receive Card Assign Pin Applying for New Card :Card [active] A Business Activity Diagram Client arrives at ATM Insert Card [CARD valid] [CARD valid] Give PIN [PIN OK] [PIN OK] [Quit] Select Service [withdraw] View Balance Client Transaction Withdraw Eject Card Client leaves ATM Glossary • ATM Card • Withdraw - Requirement List • • • • • Client shall view the balance Client shall withdraw money within a limit Client shall change the PIN Bank Clerk shall store a new CARD detail Bank Clerk shall add another account to a CARD • Shall check the CARD’s validity • Shall verify the PIN • Shall use 3-DCS (168 bits) encoding Grouping the Candidate Requirements CARD MANIPULATION – Clerk store a new CARD detail – Clerk add another account to a CARD – Clerk & Client shall fix new PIN first time – Client shall change the PIN TRANSACTIONS – Client shall view the balance (within minutes) – Client shall withdraw money from savings/ current account within the limit – Client shall transfer money within the limit Use Cases Transactions transfer withdraw Client view Balance Add structures  System’s Tasks Identified • • • • • • (1) System gets all the accounts on Card (2) System displays the details of Accounts (3) Prompts to select one (4 System prompts for the amount (5) System issue money (6) Update records (update what?) How to allocate these tasks to different classes? Use case Realization! Identify Collaborations withdraw Client withdraw :Card :Account CRC - Allocate Responsibilities Class Name Card Responsibilities Collaborations Provide Card information Provide list of Accounts Class Name Account Responsibilities Provide Account information Provide Withdrawal Account provides Account’s detail Collaborations Collaboration Diagram (Initial Idea)! Client getAllAccDetail() withdraw(acc,amm) *getAccDetail() ::Card withdraw(amm) ::Account Collaboration Diagram, with UI and CTRL objects! Client selectAccount withdraw(cID) startUI() withdraw(acc,am) proAmount ::withdrawUI 5.1 withdraw(am) ::withdrawCtrl getAllAccDetail() 1.1 *getAccDetail() ::Card Issue Cash? ::Cheque Analysis Level Class Diagram : Ite-2 ATMSavings ATMCustomer * accID balance accName * getAccID() setBalance() getBalance() * getAccDetail() withdraw(amo) ATMwdUI startUI(); selectAcc(); proAmount(); custID ATMCheque * getCustID() * accID balance oDlimit accName * getAccID() setBalance() getBalance() * * ATMCard cardNo pin status getCardID() setPIN() getPIN() setStatus() getStatus() * getAccDetail() withdraw(amo) ATMwdCTRL withdraw(cID) withdraw(aID,amo) getAllAccDetail() What next? Identify Super-Sub & Aggregations Analysis Level Class Diagram (Ite-3) ATMCustomer * ATMSavings withdraw(amo) ATMCheque oDlimit withdraw(amo) withdraw(cID) withdraw(aID,amo) accID balance accName * ATMCard getAccID() setBalance() getBalance() getAccDetail() withdraw(amo) startUI(); selectAcc(); proAmount(); custID getCustID() ATMAccount ATMwdUI ATMwdCTRL * * * cardNo pin status getCardID() setPIN() getPIN() setStatus() getStatus() getAllAccDetail() Analysis Level Class Diagram (ver-2) ATMCustomer * ATMSavings withdraw(amo) ATMCheque oDlimit withdraw(amo) ATMwdCTRL withdraw(cID) withdraw(aID,amo) ATMAccount accID balance accName getAccID() setBalance() getBalance() * custID getCustID() ATMCustAcc 1 * ATMCard getAccDetail() withdraw(amo) cardNo pin status ATMwdUI getCardID() setPIN() getPIN() setStatus() getStatus() startUI(); selectAcc(); proAmount(); getAllAccDetail() Which version is better, why? Sequence diagram with entity objects only Client :Card getAllAccDetail() :Account *getAccDetail( ) withdraw(acc,am) withdraw(am) Use Case: withdraw Sequence diagram With Boundary & Control Classes Client :withdrawCtrl :withdrawUI startUI() :Account :Card *getAllAccDetails() *getAccDetail() selectAccount() proAmount() withdraw() withdraw() Issue Cash? Use Case: withdraw State Transitions • Include relevant State Transition Diagrams (or Activity Diagrams) CARD Card() Pending Statechart fixPIN() OnUse after [1 year] OnUse Active setStatus() Blocked Lapsed ~Card() Withdraw- Operation Specification Pre- and Post-condition Pair pre-conditions: CARD is valid ACCOUNT is valid ACCOUNT is associated with CARD amount is valid post-conditions: if amount is greater than ACCOUNT.balance value of ACCOUNT.balance set equal to ACCOUNT.balance-amount value of result set equal to success otherwise value of result set equal to failure Issue Cash? Structured English- withdraw get all the accounts associated with CARD if there are more than one ACCOUNT Do while there is no more ACCOUNTS left get all the details associated with ACCOUNT display details endDo set ACCOUNT to user selected ACCOUNT else set ACCOUNT to the only existing ACCOUNT endIf if ACCOUNT.balance is greater than amount set ACCOUNT.balance to ACCOUNT.balance – amount set result to TRUE else set result to FALSE endIf return result Issue Cash? Activity Diagram- Withdraw Get Account Details [NoOfAccounts = 1] [more] [NoOfAccounts > 1] A Only Account List an Account details [no more] Get amount Get User’s Choice (say A) [amount >A balance] Result  FALSE [amount < =A balance] Issue Cash? A.balance  A.balance-amount Result  TRUE ... getCustID() ATMAccount ATMwdUI ATMwdCTRL * * * cardNo pin status getCardID() setPIN() getPIN() setStatus() getStatus() getAllAccDetail() Analysis Level Class Diagram (ver-2) ATMCustomer * ATMSavings... withdraw(amo) ATMCheque oDlimit withdraw(amo) ATMwdCTRL withdraw(cID) withdraw(aID,amo) ATMAccount accID balance accName getAccID() setBalance() getBalance() * custID getCustID() ATMCustAcc 1 * ATMCard... Diagram : Ite-2 ATMSavings ATMCustomer * accID balance accName * getAccID() setBalance() getBalance() * getAccDetail() withdraw(amo) ATMwdUI startUI(); selectAcc(); proAmount(); custID ATMCheque *

Ngày đăng: 05/12/2016, 21:48

Xem thêm

TÀI LIỆU CÙNG NGƯỜI DÙNG

  • Đang cập nhật ...

TÀI LIỆU LIÊN QUAN

w