Parth's Project Portfolio Page
Project: BookFace
BookFace replaces a paper-based system or manual tracking of books and patrons, providing greater speed/efficiency to librarians. The user interacts with it using a CLI, and it has a GUI created with JavaFX. It is written in Java, and has about 12.6 kLoC.
Given below are my contributions to the project.
- New Feature: Added the ability to extend commands more easily and handle parsing better (including subcommand handling) #97
- What it does: Improves command parsing by creating more separate parsing of commands and arguments.
- Justification: The parsing of commands was through a three-step process - processing the first command word, then the arguments, and constructing the
Command
instance. The distinction between commands and arguments was not clear. There was a lot of code duplication in the parsers as well, which was handled by using enums to associate each parse function with each possible command from the user and by makingCommandParser
abstract with a shared parse function. - Highlights: The command structure is recursive, allowing for easy extensibility with the idea of a subcommand contained within the user’s inputted command.
- Credits: The idea of using enums was taken from the iP project, where the students were encouraged to use enums. The idea of forcing all subclasses to use the parse method implemented in the abstract class was inspired by an answer on StackOverflow (see Acknowledgements).
- New Feature: Added
find book
feature. #118- Added helper util methods to improve search for keywords, ignoring case.
-
New Feature: Added
edit book
feature. #154 -
New Feature: Added
return
feature. #119 - Enhancements to existing features:
- Converted
add user
,list user
, anddelete user
to the new parsing mechanism. #97 - Converted
find user
to the new parsing mechanism. #118 - Converted
edit user
to the new parsing mechanism. #154- Highlights: As an edited book can be currently on loan, edits to either
Person
orBook
had to be reflected in the other
- Highlights: As an edited book can be currently on loan, edits to either
- Improved
loan
andreturn
commands’ logic #119- What it does: Improved
Book
fields and methods, and enhances serialisationPersons
with loanedBooks
to the JSON format
- What it does: Improved
- Improved error messages by generating them using information from the command itself #156
- Justification: The error messages were written by hand, leading to incorrect error messages if the logic for the command was updated. The error message generation also tied in with the subcommand handling, with error messages for subcommands nested within the main command.
- Updated
clear all
command, updated thehelp
window with a copy button, fixedhelp
window display issue (#156) - Improvements to code quality made
- Fix bugs with data file parsing and deserialisation #227
- Wrote tests for the whole of
JsonAdaptedBookTest.java
and for other files #234
- Converted
-
Code contributed: RepoSense link
- Project management:
- Created the team repo, set up CodeCov, add user stories as issues.
- Helped review and merge PRs on a timely basis (even after they have been merged, for example #160)
- Proposed design suggestions in PR reviews
- Created v1.2, v1.3, v1.4 milestones and the project board
- Documentation:
- User Guide:
- Added documentation for the features
add user
,delete user
,delete book
,edit book
, andedit user
#64, [#166](https://github.com/AY2223S1-CS2103-F14-4/tp/pull/166 - Made other edits such as to the ‘Notes on the Command Format’
- Added documentation for the features
- Developer Guide:
- User Guide:
- Community: