fssa-batch3 / fssa-batch3/sec_a_kishor.muruganandham__corejava_project_2

Book Module | Add Book Feature

Open
#3 0 comments 0 reactions 1 assignee Claimed by @kishor-repo View on GitHub
book-module enhancement
Dominant language
Java
Stars
7
Forks
0
PR merge metrics
No merged PRs in 30d

Description

# Creating Book Process

### User Story
As a librarian, I want to be able to add new books to the library's collection. If the book already exists in the library's records, the system should display an error message indicating that the book already exists.

### Task

- [x] Implement Data Access Object (DAO) Layer.
- [x] Implement Service Layer.
- [x] Create JUnit Test Cases.
- [x] Ensure that the tests cases are passing.
- [x] Write clear and concise comments in the code to explain complex logic.

#### DAO
- createBook()

#### Service
- addBook()

#### Junit Test
- testValidAddBook()
- testInvalidAddBook()

### Estimation
- 3 hours

# Flowchart

```mermaid
graph TD
A[[Start]] --> |Librarian Initiates Book Creation| B([Validate Book])
B --> |Valid| C([Search Existing Books])
B --> |Invalid| E{{Validation Exception}}
C --> |Book Found| F{{Service Exception}}
C --> |Book Not Found| D([Add Book])
D --> |Success| I([Book Added Successfully])
E --> |Fail| G([Failed to Add Book])
F --> |Fail| G
G --> H[[End]]
I --> H

style I fill:#dfd,stroke:#333
style G fill:#fdd,stroke:#333

Contributor guide

No contributing guide indexed for this repository

Assessment

This issue has not been assessed yet.

Get new issues in your inbox

A short digest of beginner-friendly GitHub issues.