SoftwareRequirementsSpecificationforLibrary Management System
SoftwareRequirementsSpecificationforLibrary Management System
TableofContents
1. Introduction .............................................................................. 1
1.1 Purpose ................................................................................ 1
1.2 Scope ................................................................................... 1
1.3 Definitions, Acronyms, and Abbreviations .......................... 1
1.4 References ........................................................................... 2
1.5 Overview………………………………………………………
…………………………………….2
2. OverallDescription ................................................................... 2
2.1 ProductPerspective ............................................................... 2
2.2 Product Features .................................................................. 2
2.3 UserClassesandCharacteristics ............................................. 3
2.4 OperatingEnvironment ......................................................... 3
2.5 DesignandImplementationConstraints ................................. 3
2.6 UserDocumentation ............................................................. 4
2.7 AssumptionsandDependencies ............................................. 4
3. Specific Requirements ............................................................. 4
3.1 Functional Requirements ..................................................... 4
3.2 Non-Functional Requirements ............................................. 5
4. External Interface Requirements ........................................... 5
4.1 User Interfaces .................................................................... 7
4.2 Hardware Interfaces ........................................................... 16
4.3 Software Interfaces ........................................................... 17
4.4 Communications
Interfaces…………………………………………………17
5. Future Enhancements............................................................ 18
SoftwareRequirementsSpecificationforLibrary Management System
1. Introduction
This section provides an overview of the Software Requirements Specification (SRS) for
the Library Management System (LMS).
1.1 Purpose
This document specifies the software requirements for the Library Management System
(LMS), Version 1.0. It provides a comprehensive description of the system's intended
purpose, features, operating conditions, and constraints. The LMS is designed to automate
and streamline all library operations, enhancing efficiency for librarians and improving the
user experience for members. This SRS is intended for project stakeholders, including
developers, testers, and project managers, to ensure a common understanding of the
system's requirements.
1.2 Scope
The software will be a web-based application designed to manage the core functions of a
library. The scope of the project includes:
1.3 IntendedAudienceandReadingSuggestions
. Inventory Management: Cataloging books and other media.
• User Management: Handling registration and profiles for members and staff.
• Circulation Management: Automating the process of issuing, returning, and
renewing books, including automatic fine calculation.
• AI-Powered Features: Providing personalized book recommendations, natural
language search, and borrowing pattern analysis.
SoftwareRequirementsSpecificationforLibrary Management System
• Reporting: Generating insightful reports for administrative oversight.
The system is intended for use in academic institutions, public libraries, and
corporate libraries.
SoftwareRequirementsSpecificationforLibrary Management System
1.3 Definitions, Acronyms, and Abbreviations
Term Definition
AI Artificial Intelligence
DBMS Database Management System
ERD Entity-Relationship Diagram
GUI Graphical User Interface
LMS Library Management System
ML Machine Learning
NLP Natural Language Processing
RAID Redundant Array of Independent
Disks
RBAC Role-Based Access Control
SRS Software Requirements
Specification
1.4 References:
1. IEEE Std 830-1998, IEEE Recommended Practice for Software
Requirements Specifications.
2. Django Framework Documentation: [Link]
3. FastAPI Framework Documentation: [Link]
4. MySQL Server Documentation: [Link]
5. Python Data Science Libraries: Scikit-learn, Pandas, NLTK.
SoftwareRequirementsSpecificationforLibrary Management System
1.5 Overview
This document is organized into five main sections.
Section 1 provides an introduction and overview.
Section 2 gives an overall description of the product, its users, and its
operating environment.
Section 3 details the specific functional and non-functional
requirements.
Section 4 outlines external interface requirements.
Section 5 discusses potential future enhancements. Appendices provide
supplementary information, including the data model and RBAC matrix.
SoftwareRequirementsSpecificationforLibrary Management System
2. Overall Description
This section describes the general factors that affect the product and its
requirements.
2.1 Product Perspective
The LMS is a self-contained, web-based system designed to replace or
supplement manual library management procedures. It will operate on a
client-server architecture. The front-end will be a responsive web interface
accessible via standard browsers, while the back-end will consist of an
application server, an AI/ML engine, and a relational database. It is a new
product and does not supersede any existing automated systems,
although it may replace manual or legacy processes.
2.2 Product Features
The major features of the LMS include:
• Book and Inventory Management: Add, update, delete, and search for
books and other library resources.
• User Registration and Management: Onboarding of new members and
management of user profiles and roles.
• Circulation Control: Handling check-outs, check-ins, and renewals.
• Automated Fine Calculation: Automatically computing and applying fines
for overdue items.
• Notification System: Sending automated reminders for due dates and
overdue items via email/SMS.
• Personalized Recommendations: Using ML algorithms to suggest books
to users based on their profile and borrowing history.
• Natural Language Search: Allowing users to search the catalog using
conversational queries.
• Reporting and Analytics: Providing a dashboard with key metrics and
generating detailed reports.
SoftwareRequirementsSpecificationforLibrary Management System
2.3 User Classes and Characteristics
User Class Characteristics & Responsibilities
Has complete system privileges. Responsible for system
Administrator configuration, managing user roles, and performing all
librarian functions. Possesses technical expertise.
Manages the library's day-to-day operations.
Responsibilities include managing the book catalog,
Librarian
handling circulation (issue/return), and generating reports.
Familiar with library processes.
The primary end-user of the system. Can search the
Member/ catalog, view book availability, check their borrowing
Student history, and receive personalized recommendations.
Requires basic computer literacy.
2.4 Operating Environment:
Server OS: Linux (Recommended), Windows Server.
Client OS: Windows, macOS, Linux, Android, iOS
Client Software: Modern web browser (Chrome, Firefox, Safari, Edge)
Backend Framework: Django (Python) / Spring Boot (Java) / FastAPI
Database: MySQL
SoftwareRequirementsSpecificationforLibrary Management System
2.5 Design and Implementation Constraints:
The system must be developed using a relational DBMS (MySQL).
• The backend must expose a RESTful API for communication with the
front-end.
• The system architecture must support the integration of Python-based
ML and NLP modules.
• Data storage must be fault-tolerant, recommending a RAID configuration
for production servers.
• The use of open-source technologies is mandated where feasible to
reduce licensing costs.
2.6 User Documentation:
The project will deliver the following user documentation:
• Installation and Configuration Guide
• Administrator Manual
• Librarian User Guide
• Troubleshooting FAQ
2.7 Assumptions and Dependencies:
• Users are assumed to have a stable internet connection and access to
a compatible web browser.
• The availability of third-party services for sending emails (SMTP) and
SMS messages is assumed.
• Hardware for barcode/QR code scanning is optional but required for the
full functionality of the rapid circulation feature.
SoftwareRequirementsSpecificationforLibrary Management System
3. Specific Requirements
This section contains the detailed functional and non-functional
requirements of the LMS.
3.1 Functional Requirements
3.1.1 Feature: User Management
REQ-USER-001: The system shall allow members to self-register for an
account, which will be pending approval by a Librarian or Administrator.
• REQ-USER-002: The system shall allow Administrators to create, view,
update, and delete user accounts (Librarian, Member).
• REQ-USER-003: Users shall be able to log in using their registered
email/ID and password. The system shall support a "Forgot Password"
functionality.
• REQ-USER-004: Authenticated members shall be able to view and edit
their own profile information.
• REQ-USER-005: Authenticated members shall be able to view their
current borrowings and borrowing history.
3.1.2 Feature: Book and Inventory Management
• REQ-INV-001: The system shall allow Librarians and Administrators to
add new books with details such as Title, Author, ISBN, Genre, Publisher,
and Quantity.
• REQ-INV-002: The system shall allow Librarians and Administrators to
update or delete existing book records.
• REQ-INV-003: The system shall maintain the status of each book copy
(e.g., Available, Issued, Reserved, Damaged).
3.1.3 Feature: Circulation Management
• REQ-CIRC-001: The system shall allow Librarians to issue a book to a
registered member. The issue date and due date shall be recorded.
SoftwareRequirementsSpecificationforLibrary Management System
• REQ-CIRC-002: The system shall allow Librarians to process the return
of a book.
• REQ-CIRC-003: The system shall automatically calculate fines for
overdue books based on a configurable daily rate. The fine amount shall
be added to the member's account.
• REQ-CIRC-004: The system shall allow Librarians to record fine
payments.
3.1.4 Feature: Search and Discovery
• REQ-SRCH-001: All users shall be able to search the library catalog
based on title, author, genre, or ISBN.
• REQ-SRCH-002 (NLP Search): The system shall support natural
language queries for searching books (e.g., "computer science books by
Tanenbaum").
3.1.5 Feature: AI-Driven Enhancements
• REQ-AI-001 (Recommendations): The system shall provide
personalized book recommendations to members on their dashboard,
based on their borrowing history, profile (e.g., stream, semester), and
similarity to other users.
• REQ-AI-002 (Analytics): The system shall analyze borrowing data to
identify trends, such as most popular books, peak borrowing hours, and
popular genres, presented on an analytics dashboard for Administrators.
3.1.6 Feature: Notifications
• REQ-NOTIF-001: The system shall automatically send email/SMS
notifications to members 2 days before a book's due date.
• REQ-NOTIF-002: The system shall automatically send email/SMS
notifications to members upon a book becoming overdue.
3.2 Non-Functional Requirements
Category Requirement
Performance REQ-NFR-001: Standard page loads and search query
SoftwareRequirementsSpecificationforLibrary Management System
responses shall complete in under 3 sec
up to 1000 concurrent users.
REQ-NFR-002: Report generation shall complete within
seconds for a monthly data set.
Security REQ-NFR-003: All user passwords must be hashed and
salted befour storage.
REQ-NFR-004: All web traffic must be encrypted using
HTTPS.
REQ-NFR-005: Access to system functions must be
restricted based on user role.
Reliability REQ-NFR-006: The system shall achieve an uptime of.
99.5% or higher.
REQ-NFR-007: The system must ensure data integrity
through database transactions and have
a scheduled backup mechanism.
Scalability REQ-NFR-008: The system architecture must be
scalable to handle a 50% increase in
users and book inventory over two years
without performance degradation.
Usability REQ-NFR-009: The UI shall be intuitive and require
minimal training for members and
librarians.
REQ-NFR-010: The web interface must be responsive
and functional on desktop,
tablet, and mobile devices.
Portability REQ-NFR-011: The system shall be deployable on both
Linux and Windows server
environments.
4. External Interface Requirements
4.1 User Interfaces
The system will feature a clean, modern, and responsive web-based
GUI built with HTML5, CSS3, and JavaScript (utilizing a framework like
Bootstrap or Materialize). The interface will be designed for accessibility
and ease of use, with clear navigation and feedback mechanisms.
4.2 Hardware Interfaces
SoftwareRequirementsSpecificationforLibrary Management System
The system shall be capable of interfacing with standard USB barcode
or QR code scanners to facilitate faster book issuing and returning. This
interface is optional and the system will remain fully functional without it.
4.3 Software Interfaces
• Database: The system will interface with a MySQL relational database
via a standard database connector.
• Email Service: The system will interface with an external SMTP server
(e.g., SendGrid, Mailgun) via an API to send email notifications.
• SMS Service: The system will interface with an external SMS gateway
(e.g., Twilio) via an API to send SMS notifications.
• AI/ML Libraries: The backend application will interface with Python
libraries such as Pandas, Scikit-learn, and NLTK/spaCy to implement
the AI features.
4.4 Communications Interfaces
• HTTP/S: All communication between the client (web browser) and the
server will use the HTTPS protocol for security.
• REST API: The backend will expose a set of RESTful APIs for the
frontend to consume.
5. Future Enhancements
This section lists potential enhancements that are not within the scope of
version 1.0 but may be considered for future releases.
• Mobile Application: A dedicated Android/iOS application for members.
• Voice-Activated Search: Integration of speech-to-text functionality for
hands-free searching.
• Digital Library Integration: API integration with national digital libraries
(e.g., NDL) or academic journals (e.g., J-Gate).
• Self-Checkout Kiosk: A dedicated interface for a self-service
checkout/check-in kiosk.
SoftwareRequirementsSpecificationforLibrary Management System
Context- Level DFD:
Level-1 DFD:
SoftwareRequirementsSpecificationforLibrary Management System
Level-2 DFD:
USE CASE DIAGRAM:
SoftwareRequirementsSpecificationforLibrary Management System
Code:
#include <iostream>
#include <string>
#include <vector>
using namespace std;
class Borrower {
public:
void makeReservation();
void removeReservation();
void lendItem();
void returnItem();
};
class Librarian {
public:
void lendItem();
void returnItem();
void performMaintenance();
};
class Item {
private:
string title;
string author;
bool available;
public:
Item(string t, string a);
void addItem();
void removeItem();
void updateItem();
void setAvailability(bool status);
bool isAvailable() const;
};
class BorrowerRecord {
private:
string borrowerName;
SoftwareRequirementsSpecificationforLibrary Management System
int borrowerID;
public:
BorrowerRecord(string name, int id);
void addBorrower();
void removeBorrower();
void updateBorrower();
};
class Maintenance {
public:
void addTitle();
void removeTitle();
void updateTitle();
void addItem();
void removeItem();
void addBorrower();
void removeBorrower();
};
class LibraryManagementSystem {
private:
vector<Item> items;
vector<BorrowerRecord> borrowers;
public:
void makeReservation(string borrowerName, string bookTitle);
void removeReservation(string borrowerName, string bookTitle);
void lendItem(string borrowerName, string bookTitle);
void returnItem(string borrowerName, string bookTitle);
void maintenance();
};
Item::Item(string t, string a) : title(t), author(a), available(true) {}
void Item::addItem() { cout << "Item added.\n"; }
void Item::removeItem() { cout << "Item removed.\n"; }
void Item::updateItem() { cout << "Item updated.\n"; }
void Item::setAvailability(bool status) { available = status; }
bool Item::isAvailable() const { return available; }
BorrowerRecord::BorrowerRecord(string name, int id) :
borrowerName(name), borrowerID(id) {}
void BorrowerRecord::addBorrower() { cout << "Borrower added.\n"; }
void BorrowerRecord::removeBorrower() { cout << "Borrower
SoftwareRequirementsSpecificationforLibrary Management System
removed.\n"; }
void BorrowerRecord::updateBorrower() { cout << "Borrower
updated.\n"; }
void Maintenance::addTitle() { cout << "Title added.\n"; }
void Maintenance::removeTitle() { cout << "Title removed.\n"; }
void Maintenance::updateTitle() { cout << "Title updated.\n"; }
void Maintenance::addItem() { cout << "Item added.\n"; }
void Maintenance::removeItem() { cout << "Item removed.\n"; }
void Maintenance::addBorrower() { cout << "Borrower added to
system.\n"; }
void Maintenance::removeBorrower() { cout << "Borrower removed from
system.\n"; }
void Borrower::makeReservation() { cout << "Reservation made.\n"; }
void Borrower::removeReservation() { cout << "Reservation removed.\n";
}
void Borrower::lendItem() { cout << "Lending item request sent to
librarian.\n"; }
void Borrower::returnItem() { cout << "Returning borrowed item.\n"; }
void Librarian::lendItem() { cout << "Librarian lending item.\n"; }
void Librarian::returnItem() { cout << "Librarian receiving returned
item.\n"; }
void Librarian::performMaintenance() { cout << "Librarian performing
maintenance.\n"; }
void LibraryManagementSystem::makeReservation(string
borrowerName, string bookTitle) {
cout << borrowerName << " reserved: " << bookTitle << endl;
}
void LibraryManagementSystem::removeReservation(string
borrowerName, string bookTitle) {
cout << borrowerName << " canceled reservation: " << bookTitle <<
endl;
}
void LibraryManagementSystem::lendItem(string borrowerName, string
bookTitle) {
cout << borrowerName << " borrowed: " << bookTitle << endl;
}
void LibraryManagementSystem::returnItem(string borrowerName, string
bookTitle) {
cout << borrowerName << " returned: " << bookTitle << endl;
SoftwareRequirementsSpecificationforLibrary Management System
}
void LibraryManagementSystem::maintenance() {
cout << "System maintenance in progress...\n";
}
int main() {
LibraryManagementSystem system;
[Link]("Alice", "Data Structures");
[Link]("Alice", "Data Structures");
[Link]("Alice", "Data Structures");
[Link]();
return 0;
}
Diagram:
SoftwareRequirementsSpecificationforLibrary Management System
CLASS DIAGRAM:
CODE:
#include <string>
#include <vector>
using namespace std;
class NotificationSystem {
private:
string username;
string emailId;
string bookDetails;
public:
void dueDates();
void newArrival();
void trendingBooks();
void bookRecommendations();
};
class Inventory {
private:
string bookName;
int bookId;
string authorName;
string genre;
string dateAdded;
public:
void addRemoveBooks();
void checkStatistics();
void updateDetails();
};
class User {
private:
string username;
string emailId;
long phoneNo;
public:
SoftwareRequirementsSpecificationforLibrary Management System
void login();
void logout();
void bookIssue();
void makePayments();
};
class CataloguePage {
private:
string authorName;
string bookName;
int bookId;
string dateAdded;
public:
void searchByName();
void searchByAuthor();
void searchByDescription();
void searchByGenre();
void searchByTrend();
void selectBook();
};
class Admin {
private:
string adminName;
string emailId;
long phoneNo;
public:
void login();
void logout();
void addBooks();
void updateBooks();
void removeBooks();
void checkNoOfMember();
void addMembers();
void updateMembers();
void removeMembers();
void checkStatistics();
};
// BillPayments Class
class BillPayments {
SoftwareRequirementsSpecificationforLibrary Management System
private:
string username;
string paymentMethod;
int totalSum;
public:
void makePayment();
void cancelMembership();
void refund();
};
DIAGRAM:
SEQUENCE DIAGRAM:
SoftwareRequirementsSpecificationforLibrary Management System
CODE:
#include <iostream>
#include <string>
#include <optional>
enum class MemberType {
REGULAR,
PREMIUM
};
std::string memberTypeToString(MemberType t) {
return (t == MemberType::PREMIUM) ? "PREMIUM" : "REGULAR";
}
class Book {
public:
Book(std::string id, std::string title)
: id_(std::move(id)), title_(std::move(title)), isIssued_(true) {}
struct IssueDetail {
std::string borrowerId;
int issueDay; // simplified day counter
int dueDay;
};
std::optional<IssueDetail> getIssueDetail() const {
if (!isIssued_) return std::nullopt;
return IssueDetail{borrowerId_, issueDay_, dueDay_};
}
void setIssueInfo(const std::string& borrowerId, int issueDay, int
dueDay) {
borrowerId_ = borrowerId;
issueDay_ = issueDay;
dueDay_ = dueDay;
isIssued_ = true;
}
void markReturned() {
isIssued_ = false;
SoftwareRequirementsSpecificationforLibrary Management System
borrowerId_.clear();
}
bool isIssued() const { return isIssued_; }
std::string id() const { return id_; }
std::string title() const { return title_; }
private:
std::string id_;
std::string title_;
bool isIssued_ = false;
// simple issue info:
std::string borrowerId_;
int issueDay_ = 0;
int dueDay_ = 0;
};
class MemberRecord {
public:
MemberRecord(std::string memberId, MemberType type)
: memberId_(std::move(memberId)), type_(type), fineAmount_(0.0)
{}
bool validate() const {
return !memberId_.empty();
}
// Step 3: get member type
MemberType getMemberType() const { return type_; }
void addFine(double amount) {
fineAmount_ += amount;
}
double getFineAmount() const { return fineAmount_; }
void payFine(double amount) {
if (amount >= fineAmount_) {
amountPaid_ += fineAmount_;
fineAmount_ = 0.0;
} else {
fineAmount_ -= amount;
SoftwareRequirementsSpecificationforLibrary Management System
amountPaid_ += amount;
}
}
void print() const {
std::cout << "MemberRecord[" << memberId_ << "] Type: " <<
memberTypeToString(type_)
<< " Outstanding fine: " << fineAmount_ << "\n";
}
std::string id() const { return memberId_; }
private:
std::string memberId_;
MemberType type_;
double fineAmount_;
double amountPaid_ = 0.0;
};
class Bill {
public:
Bill(double amountDue, const std::string& memberId)
: amountDue_(amountDue), memberId_(memberId), paid_(false) {}
void showBill() const {
std::cout << "Bill for member '" << memberId_ << "': Amount due = "
<< amountDue_ << "\n";
}
void pay() {
if (!paid_) {
paid_ = true;
std::cout << "Bill: Payment received for " << amountDue_ << "\n";
} else {
std::cout << "Bill: Already paid.\n";
}
}
bool isPaid() const { return paid_; }
double amount() const { return amountDue_; }
private:
SoftwareRequirementsSpecificationforLibrary Management System
double amountDue_;
std::string memberId_;
bool paid_;
};
fine/payment.
class Transaction {
public:
void addTransactionEntry(const std::string& entry) {
entries_ += entry + "\n";
}
void printLog() const {
std::cout << "Transaction log:\n" << entries_;
}
private:
std::string entries_;
};
class Librarian {
public:
sequence diagram.
void returnBook(Book& book, MemberRecord& member, int
currentDay, Transaction& txn) {
std::cout << "1: validate member\n";
if (![Link]()) {
std::cout << "-> Member validation failed. Aborting return.\n";
return;
}
std::cout << "-> Member validated.\n\n";
std::cout << "2: get issue detail from Book\n";
auto issueOpt = [Link]();
if (!issueOpt) {
std::cout << "-> Book is not issued; nothing to return.\n";
return;
}
auto issue = *issueOpt;
std::cout << "-> IssueDetail: borrower=" << [Link]
<< ", issueDay=" << [Link]
<< ", dueDay=" << [Link] << "\n\n";
SoftwareRequirementsSpecificationforLibrary Management System
std::cout << "3: get member type from MemberRecord\n";
MemberType mtype = [Link]();
std::cout << "-> Member type is " << memberTypeToString(mtype)
<< "\n\n";
double fine = calculateFine([Link], currentDay, mtype);
std::cout << "5: calculate fine -> fine = " << fine << "\n\n";
Bill *billPtr = nullptr;
if (fine > 0.0) {
std::cout << "4: <<create>> Bill/Transaction record for fine\n";
Bill bill(fine, [Link]());
[Link]();
std::cout << "6: add fine and member details to transaction\n";
[Link]("Fine added for member " +
[Link]() + ": " + std::to_string(fine));
[Link](fine);
std::cout << "7: fine paid (simulate payment)\n";
[Link](); // mark bill paid
[Link](fine);
[Link]("Fine paid for member " + [Link]()
+ ": " + std::to_string(fine));
billPtr = nullptr;
std::cout << "\n";
} else {
std::cout << "-> No fine required.\n\n";
}
std::cout << "8: update book status\n";
[Link]();
[Link]("Book " + [Link]() + " returned.");
std::cout << "-> Book '" << [Link]() << "' marked as
returned.\n\n";
std::cout << "9: update member record\n";
[Link]("Member record updated for " +
[Link]());
[Link]();
SoftwareRequirementsSpecificationforLibrary Management System
std::cout << "\nReturn sequence complete.\n\n";
}
private:
static double calculateFine(int dueDay, int returnDay, MemberType
mtype) {
int daysLate = returnDay - dueDay;
if (daysLate <= 0) return 0.0;
double ratePerDay = (mtype == MemberType::PREMIUM) ? 1.0 :
2.5;
return daysLate * ratePerDay;
}
};
int main() {
Book book("B1001", "The C++ Programming Language");
[Link]("M123", 10, 20);
MemberRecord member("M123", MemberType::REGULAR);
Transaction txn;
Librarian librarian;
int currentDay = 25;
std::cout << "=== Begin return flow ===\n\n";
[Link](book, member, currentDay, txn);
std::cout << "=== Transaction summary ===\n";
[Link]();
return 0;
}
SoftwareRequirementsSpecificationforLibrary Management System
DIAGRAM:
STATE MACHINE DIAGRAM:
SoftwareRequirementsSpecificationforLibrary Management System
CODE:
#include <iostream>
using namespace std;
class LibraryProcess {
public:
LibraryProcess();
~LibraryProcess();
void start();
void login();
void searchBook();
void requestBook();
void receiveBook();
void returnBook();
void payFine();
void updateProfileAndSignout();
void stop();
void nextState(string event);
private:
string currentState;
};
LibraryProcess::LibraryProcess() {
currentState = "Start";
}
LibraryProcess::~LibraryProcess() {
}
void LibraryProcess::start() {
cout << "State: Start" << endl;
currentState = "Login";
}
void LibraryProcess::login() {
cout << "State: Login" << endl;
currentState = "SearchBook";
SoftwareRequirementsSpecificationforLibrary Management System
void LibraryProcess::searchBook() {
cout << "State: SearchBook" << endl;
currentState = "RequestBook";
}
void LibraryProcess::requestBook() {
cout << "State: RequestBook" << endl;
currentState = "ReceiveBook";
}
void LibraryProcess::receiveBook() {
cout << "State: ReceiveBook" << endl;
currentState = "ReturnBook";
}
void LibraryProcess::returnBook() {
cout << "State: ReturnBook" << endl;
currentState = "PayFine";
}
void LibraryProcess::payFine() {
cout << "State: PayFine" << endl;
currentState = "UpdateProfileAndSignout";
}
void LibraryProcess::updateProfileAndSignout() {
cout << "State: UpdateProfileAndSignout" << endl;
currentState = "Stop";
}
void LibraryProcess::stop() {
cout << "State: Stop" << endl;
}
void LibraryProcess::nextState(string event) {
// TODO: Implement state transition logic based on event
SoftwareRequirementsSpecificationforLibrary Management System
// Main driver
int main() {
LibraryProcess process;
[Link]();
[Link]();
[Link]();
[Link]();
[Link]();
[Link]();
[Link]();
[Link]();
[Link]();
return 0;
}
DIAGRAM:
SoftwareRequirementsSpecificationforLibrary Management System
ACTIVITY DIAGRAM:
SoftwareRequirementsSpecificationforLibrary Management System
CODE:
#include "BookIssueProcess.h"
#include <iostream>
using namespace std;
BookIssueProcess::BookIssueProcess() {
// TODO: Initialize attributes
bookAvailable = false;
memberValid = false;
maxQuotaExceeded = false;
}
BookIssueProcess::~BookIssueProcess() {
// TODO: Cleanup code
}
void BookIssueProcess::enquiryAboutBooks() {
// TODO: Implement enquiry about books
cout << "Activity: Enquiry about books" << endl;
}
void BookIssueProcess::checkAvailabilityOfBook() {
// TODO: Implement check availability of book
cout << "Activity: Check availability of book" << endl;
}
void BookIssueProcess::validateMember() {
// TODO: Implement validate member
cout << "Activity: Validate member" << endl;
}
void BookIssueProcess::registerMember() {
// TODO: Implement register member
cout << "Activity: Register member" << endl;
}
void BookIssueProcess::checkNumberOfBooksIssued() {
// TODO: Implement check number of books issued to member
cout << "Activity: Check number of books issued to member" << endl;
}
SoftwareRequirementsSpecificationforLibrary Management System
void BookIssueProcess::issueBook() {
// TODO: Implement issue book
cout << "Activity: Issue book" << endl;
}
void BookIssueProcess::addMemberBookAndIssueDetails() {
// TODO: Implement add member, book, and issue details
cout << "Activity: Add member, book and issue details" << endl;
}
void BookIssueProcess::updateBookStatus() {
// TODO: Implement update book status
cout << "Activity: Update book status" << endl;
}
void BookIssueProcess::bookNotAvailable() {
// TODO: Implement book not available case
cout << "Activity: Book not available" << endl;
}
void BookIssueProcess::bookNotIssued() {
// TODO: Implement book not issued case
cout << "Activity: Book not issued" << endl;
}
SoftwareRequirementsSpecificationforLibrary Management System
DIAGRAM:
SoftwareRequirementsSpecificationforLibrary Management System
JACKSON STRUCTURED DESIGN CHART(JSD):
CODE:
#include <stdio.h>
#include <string.h>
struct Book {
int id;
char title[50];
char author[50];
};
int main() {
struct Book library[100];
int count = 0;
int choice, i, id;
char searchTitle[50];
while (1) {
printf("\n=== Library Management System ===\n");
printf("1. Add Book\n");
printf("2. Display All Books\n");
printf("3. Search Book by Title\n");
printf("4. Exit\n");
printf("Enter your choice: ");
scanf("%d", &choice);
getchar();
if (choice == 1) {
printf("Enter Book ID: ");
scanf("%d", &library[count].id);
getchar();
printf("Enter Book Title: ");
gets(library[count].title);
printf("Enter Author Name: ");
gets(library[count].author);
count++;
printf("Book added successfully!\n");
}
else if (choice == 2) {
SoftwareRequirementsSpecificationforLibrary Management System
printf("\n--- All Books ---\n");
for (i = 0; i < count; i++) {
printf("ID: %d | Title: %s | Author: %s\n",
library[i].id, library[i].title, library[i].author);
}
}
else if (choice == 3) {
printf("Enter title to search: ");
gets(searchTitle);
int found = 0;
for (i = 0; i < count; i++) {
if (strcmp(library[i].title, searchTitle) == 0) {
printf("Book found! ID: %d | Author: %s\n",
library[i].id, library[i].author);
found = 1;
break;
}
}
if (!found) printf("Book not found.\n");
}
else if (choice == 4) {
printf("Exiting... Goodbye!\n");
break;
}
else {
printf("Invalid choice! Try again.\n");
}
}
return 0;
}
SoftwareRequirementsSpecificationforLibrary Management System
DIAGRAM:
SoftwareRequirementsSpecificationforLibrary Management System
GANTT CHART:
Library Management System
7-20 8-9 8-29 9-18 10-8 10-28 11-17
Requirement Analysis and Planning
System Design
Implementation and Development
Testing and Quality Assurance
Deployment
Start Date Duration in Days
SoftwareRequirementsSpecificationforLibrary Management System
NETWORK DIAGRAM:
Network Diagram for Library Management System
Client Devices
Student Client Devices Librarian Client
Web Server
Application Layer
Authentication Database
Server Server
Data Layer
Cloud Storage
Book API
External Entity
(Email Notifications
Server)
SoftwareRequirementsSpecificationforLibrary Management System