Case Study-Software Requirement PDF
Case Study-Software Requirement PDF
Case Study-Software Requirement PDF
Banking System
Lecture # 40
1
Requirements Document
• The requirements document is a formal
document used to communicate the
requirements to customers, engineers
and managers
• It is also known as software
requirements specifications or SRS
2
Requirements Document
• The services and functions which the
system should provide
• The constraints under which the system
must operate
• Overall properties of the system i.e.,
constraints on the system’s emergent
properties
3
Today’s Topics
• In this lecture, we’ll discuss the
requirements document of the Banking
system that we have been talking about
in this course
• Let’s develop a template based on the
IEEE standard
4
SRS for the Banking System
• Preface
• Introduction
• Glossary
• Specific requirements
• Appendices
– Use-case model
– Object model
– Data-flow model
5
SRS for the Banking System
• Preface
– This should define the expected readership of the
document and describe its version history including a
rationale for creation of a new version and a summary
of the changes made in each version
• Introduction
– This should define the product in which the software is
embedded, its expected usage and present an overview
of the functionality of the control software
6
SRS for the Banking System
• Glossary
– This should define all technical terms and abbreviations
used in the document
• Specific requirements
– This should define specific requirements for the system
using natural language with the help of diagrams, where
appropriate
• Appendices
– Use-case model
– Object model
– Data-flow model
7
Software Requirements
Specifications for the Banking
System
8
1. Preface
• This document, Software
Requirements Specification (SRS), is
created to document the software
requirements for the Banking System,
as described in section 2, Introduction,
of this document
9
1. Preface
• This document was created on the request
of the ‘XYZ Bank Inc.’ – the ‘Client’. The
creator of this document is ‘A Software
House Inc.’ – ‘Vendor’. The ‘Client’ has
asked the ‘Vendor’ to develop an SRS for
the Banking System. The ‘Vendor’ will
also be responsible for the development of
the software based on this SRS
10
1. Preface
• This is the first version of the SRS.
11
2. Introduction
• This section documents an overview of
the functionality expected from the
software for the Banking System
• We’ll review the functionality of the
software to be developed
12
2. Introduction
• A bank has several automated teller machines (ATMs), which are
geographically distributed and connected via a wide area network to a
central server. Each ATM machine has a card reader, a cash dispenser,
a keyboard/display, and a receipt printer. By using the ATM machine,
a customer can withdraw cash from either checking or savings
account, query the balance of an account, or transfer funds from one
account to another. A transaction is initiated when a customer inserts
an ATM card into the card reader. Encoded on the magnetic strip on
the back of the ATM card are the card number, the start date, and the
expiration date. Assuming the card is recognized, the system validates
the ATM card to determine that the expiration date has not passed, that
the user-entered PIN (personal identification number) matches the PIN
maintained by the system, and that the card is not lost or stolen. The
customer is allowed three attempts to enter the correct PIN; the card is
confiscated if the third attempt fails. Cards that have been reported lost
or stolen are also confiscated.
13
2. Introduction
• If the PIN is validated satisfactorily, the customer is prompted for a
withdrawal, query, or transfer transaction. Before withdrawal
transaction can be approved, the system determines that sufficient
funds exist in the requested account, that the maximum daily limit will
not be exceeded, and that there are sufficient funds available at the
local cash dispenser. If the transaction is approved, the requested
amount of cash is dispensed, a receipt is printed containing information
about the transaction, and the card is ejected. Before a transfer
transaction can be approved, the system determines that the customer
has at least two accounts and that there are sufficient funds in the
account to be debited. For approved query and transfer requests, a
receipt is printed and card ejected. A customer may cancel a
transaction at any time; the transaction is terminated and the card is
ejected. Customer records, account records, and debit card records are
all maintained at the server.
14
2. Introduction
• An ATM operator may start up and close
down the ATM to replenish the ATM cash
dispenser and for routine maintenance. It is
assumed that functionality to open and close
accounts and to create, update, and delete
customer and debit card records is provided
by an existing system and is not part of this
problem.
15
3. Glossary
• ATM: Automated Teller Machine
• PIN: Personal Identification Number
16
4. Specific Requirements
1. The XYZ Bank Inc. can have many automated
teller machines (ATMs), and the new software
system shall provide functionality on all ATMs.
25
4. Specific Requirements
16. The customer records, account records,
and debit card records will all be
maintained at the server and shall not be
the responsibility of the system.
17. The system shall enable an ATM operator
to shutdown or start up an ATM for
routine maintenance.
26
4. Specific Requirements
18. The system shall enable an ATM operator
to add cash to the cash dispenser.
19. The system shall not be responsible for
opening or closing of accounts, and to
create, update, and delete customer and
debit card records. These tasks are
performed elsewhere by a bank.
27
4. Specific Requirements
20. The system shall be linked with the bank
server through communication systems,
which are beyond the scope of the current
system. It is assumed that this facility is
always available.
21. The system shall not be responsible for
the maintenance of the hardware devices
of the ATM or network facilities.
28
5. Appendices
• 5.1 Use-case model
• 5.2 Object model
• 5.3 Functional model
– 5.3.1 Data-flow model
– 5.3.2 SADT model
• 5.4 Dynamic model
– 5.4.1 Statecharts
– 5.4.2 Interaction diagrams
29
Use Case Model
30
Uses Case Diagram for ATM
Customer
Withdraw
funds «include»
ATM Validate
«include» PIN
Customer Query
account
«include»
Transfer
funds
31
Use Case Diagram for ATM
Operator
Add
cash
Startup
Operator
Shutdown
32
Use Case Diagram for ATM
Withdraw
funds «include»
ATM Validate
«include» PIN
Customer Query
account
«include»
Transfer Add
funds cash
Startup
Operator
Shutdown
33
Object Model
34
Conceptual Static Model for
Problem Domain: Physical Classes
Maintains
ATM Operator
1 1
1 1 1 1
1 1 1
Reads Dispenses Prints
1 1 1
1..* Owns
Provides
1..* 0..1 access to 1..* *
1..* Modifies
DebitCard Account ATMTransaction
1,2 *
CardAccount 36
Banking System Context Class
Diagram
1 Operator
1..*
CardReader
1
1
1..* 1
ReceiptPrinter Interacts
1
with
1 Banking
1 1 1..* Operator
1 1 System
1..*
ATM
ATMCustomer 1
Customer
CashDispenser 1..*
1 37
Banking System: Major Subsystems
1
ReceiptPrinter Operator
1
Banking
System
1
1 1
CardReader
1 ATMClient 1..* 1 BankServer
Subsystem Subsystem
1
1
1
CashDispenser 1
ATMCustomer
38
Banking System External Classes
and Interfaces Classes
Banking
System
1 1 1
CardReader
CardReader
Interface
1 Receipt
1 1 Operator
ReceiptPrinter Printer Operator
Interface 1 1
Interface
1 1
1 1 1
ATMCustomer ATMCustomer 1
ATM Interface
Customer
1 1
1 Interface 39
ATM Client Subsystem Classes
ATMClientSubsystem
CardReader ATMControl
Customer
Interface Interface
ATMTransaction
ReceiptPrinter
ATMCard
Operator
CashDispenser Interface
Interface
ATMCash
40
Data Flow Diagrams
41
System Context Diagram
Inputs
from
ATM Customer
Customer Bank
Cash
Requests
Outputs Receipt 0
to ATM Bank
Customer System
Operator
Instructions Bank
Responses
ATM Operator
Operator Responses
42
Data Flow Diagram – Level 1
Inputs
from ATM Card
Customer and
Transactions Messages
to Bank Bank
Cash Interface Requests
2 Messages 1 4
from
Interface Customer Control Interface
with Interface ATM with
Receipt Customer Bank
Bank
Messages to Messages Responses
Outputs Customer Interface Messages from from Bank
to Operator Interface Interface
Customer Messages to
Operator Interface
ATM 3
Cash Interface
Operator with Operator
Instructions Operator Responses 43
Level 2 DFD: Interface with Customer
Card ATM Card
and Cash
Info
Eject Transactions
2.1 Card 2.3
Read and Dispense Dispense
Validate Cash Cash
Confiscate 1
Card Card Control
Card ATM
ATM
Inserted Cash
Transaction User Input
Info Read Print
Cancelled Receipt 2.4
2.2 Display Print
PIN
Process Message Receipt
User Inputs
Cancel and Display Display 44
Messages Receipt
Level 2 DFD: Interface with Operator
Shutdown
ATM 1 3.2
Shutdown/Startup Display
Control
Started Display Messages
ATM
Messages
47
Banking System Context Diagram
Software Tools
Networks
and Databases 48
SADT Level 1 Diagram
ATM Usage Bank Lost/Stolen
Terms and Approvals Cards List
Conditions
Software Tools
Networks
and Databases 49
ATM Usage Lost/Stolen ATM
Terms and Cards Conditions
Conditions Bank
Approvals
Card Read & Validate Dispense Cash
Valid
Info Card Cash
A-1-1 Card A-1-3
Info
PIN
Process Display
Transaction Info
Cancel Request Messages
A-1-2 ATM
Conditions
Receipt
Data Print Receipt
SADT Level 2 Receipt
A-1-4
50
SADT Level 1 Diagram
ATM Usage
Terms and
Conditions
Shutdown
Message
Perform
Startup Display
Operator
Message Messages
Services
Cash
A-2
Amount
51
Statecharts
52
Statechart for ATM Control:
Validate PIN Use Case
1.2: Card Inserted / Idle
Waiting 1.3: Get PIN
Entry / Display
for PIN Welcome
2.4: PIN Entered /
2.5: Validate PIN
Validating PIN
2.6: Valid PIN /
2.7: Display Menu,
2.7a: Update Status
Waiting for
Customer Choice 53
Statechart for ATM Control:
Withdraw Funds Use Case
Idle
Entry / Display Terminating
Welcome 3.18: Card Ejected /
3.19: Display Ejected
Ejecting
Waiting for
3.15: Receipt Printed /
Customer Choice 3.16: Eject
Printing
3.3: Withdrawal Selected /
3.4: Request Withdrawal, 3.10: Cash Dispensed /
3.4a: Display Wait 3.11: Print Receipt,
3.11a: Display Cash Dispensed,
Processing 3.5: Withdrawal OK / 3.11b: ACK Cash Dispensed
Withdrawal 3.6: Dispense Cash, Dispensing
3.6a: Update Status 54
Top-Level ATM Control Statechart
Insufficient Cash / Eject
Closed Down
After (Elapsed Time)
Entry / Display [Closedown Was Requested]
System Down
Startup Closedown
59
Collaboration Diagram: ATM Client
Validate PIN Use Case
:BankServer
1: Card
Reader
Input
1.2: Card
:CardReader Inserted 2.5: Validate PIN 2.6: [Valid]
:CardReader
Interface (Customer Info) Valid PIN
1.1: Card
Input Data
:ATM
2.4: PIN Entered Control
:ATMCard (Customer Info)
1.3: Get
PIN 2.7a: Update
2.2: Card 2.1: Card Status
Data Request 2.7: Display
1.4: PIN Prompt Menu
2.8: Selection Menu
:Customer :ATM
Interface Transaction
2: PIN Input 2.3: Customer Info 60
Collaboration Diagram: ATM Client
Withdraw Funds Use Case
61
Consolidated Collaboration Diagram
for ATM Client Subsystem
62
Sequence Diagram
63
Sequence Diagram: ATM Client
Validate PIN Use Case - 1
1: Card
Reader Input
1.1: Card Input Data
1.2: Card Inserted
1.3: Get PIN
1.4: PIN Prompt
64
Sequence Diagram: ATM Client
Validate PIN Use Case - 2
2: PIN Input
65
Sequence Diagram: ATM Client
Validate PIN Use Case - 3
66
Sequence Diagram: ATM Client
Withdraw Funds Use Case
67
Summary
69